Пример #1
0
        protected void GdvLabelList_RowCommand(object sender, CommandEventArgs e)
        {
            bool flag = false;

            switch (e.CommandName)
            {
            case "Deleted":
                if (LabelManage.Delete(e.CommandArgument.ToString()))
                {
                    AdminPage.WriteSuccessMsg("删除成功", "LabelManage.aspx");
                    return;
                }
                AdminPage.WriteErrMsg("删除失败", "LabelManage.aspx");
                return;

            case "Copy":
                if (LabelManage.Copy(e.CommandArgument.ToString()))
                {
                    AdminPage.WriteSuccessMsg("复制成功", "LabelManage.aspx");
                    return;
                }
                AdminPage.WriteErrMsg("复制失败", "LabelManage.aspx");
                return;
            }
            flag = false;
        }
Пример #2
0
 protected void BtnDel_Click(object sender, EventArgs e)
 {
     if (this.GdvLabelList.SelectList.Length <= 0)
     {
         AdminPage.WriteErrMsg("<li>对不起,您还没选择要删除的标签!</li>");
     }
     else if (LabelManage.Delete(this.GdvLabelList.SelectList.ToString()))
     {
         this.GdvLabelList.DataBind();
     }
     else
     {
         AdminPage.WriteErrMsg("删除失败!");
     }
 }