protected void btnDelete_Click(object sender, EventArgs e) { var btnModify = (sender as ASPxButton); int index = Convert.ToInt32(btnModify.CommandArgument); GVCourseInfo.DeleteRow(index); GVCourseInfo.DataBind(); Response.Write("<script>alert('课程删除成功!')</script>"); }
protected void btnSave_Click(object sender, EventArgs e) { GVCourseInfo.UpdateEdit(); GVCourseInfo.DataBind(); Response.Write("<script>alert('课程编辑成功!')</script>"); }