protected void GridView1_RowCommand(object sender, GridViewCommandEventArgs e)
{
//e.CommandArgument获得命令行的索引
if (e.CommandName == "SetNotice")
{
if (!demo.methods(Convert.ToInt32(this.GridView1.DataKeys[Convert.ToInt32(e.CommandArgument)].Value),
userid))
{
base.MessageBox(string.Empty, OpNotice.strErrMsg);
}
else
{
base.MessageBox(string.Empty, "设置成功");
DataBinds();
}
}
}
{
//e.CommandArgument获得命令行的索引
if (e.CommandName == "SetNotice")
{
if (!demo.methods(Convert.ToInt32(this.GridView1.DataKeys[Convert.ToInt32(e.CommandArgument)].Value),
userid))
{
base.MessageBox(string.Empty, OpNotice.strErrMsg);
}
else
{
base.MessageBox(string.Empty, "设置成功");
DataBinds();
}
}
}