Web/Admin/ruyu/RuyuList.aspx.cs
(开头部分) 2KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
using System;
using System.Data;
using System.IO;
using System.Web.UI;
using System.Web.UI.WebControls;
namespace Maticsoft.Web.Admin.ruyu
{
public partial class RuyuList : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
ruyuLoad();
}
}
#region 删除删除信息
protected void imgdel_Click(object sender, ImageClickEventArgs e)
{
Maticsoft.BLL.TuyuInfo probll = new Maticsoft.BLL.TuyuInfo();
int index = 0;
for (int i = 0; i < datagong.Items.Count; i++)
{
CheckBox cb = (CheckBox)datagong.Items[i].FindControl("del") as CheckBox;
if (cb.Checked == true)
{
index = int.Parse(datagong.DataKeys[i].ToString());
probll.Delete(index);
}
}
Page.ClientScript.RegisterStartupScript(this.GetType(), "", "<script>alert('删除成功....')</script>");
ruyuLoad();
}
#endregion
private void ruyuLoad()
{
Maticsoft.BLL.TuyuInfo probll = new Maticsoft.BLL.TuyuInfo();
DataSet ds = probll.GetAllList();
DataView dv = ds.Tables[0].DefaultView;
PagedDataSource pds = new PagedDataSource();
AspNetPager1.RecordCount = dv.Count;
pds.DataSource = dv;
pds.AllowPaging = true;
pds.CurrentPageIndex = AspNetPager1.CurrentPageIndex - 1;
pds.PageSize = AspNetPager1.PageSize;
datagong.DataSource = pds;
datagong.DataKeyField = "E_yuID";
datagong.DataBind();
}
protected void AspNetPager1_PageChanged(object sender, EventArgs e)
{
ruyuLoad();
}
protected void datagong_ItemCommand(object source, DataListCommandEventArgs e)
后面还有 18 行代码,购买后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明
AI 解读
登录后可用,每次 10 积分,解读结果公开显示在下面。
还没有人解读过这个文件。
