/// <summary> /// 批量暂停 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> protected void BtnPause_Click(object sender, EventArgs e) { string Ids = ""; for (int i = 0; i <= GridView1.Rows.Count - 1; i++) { CheckBox cbox = (CheckBox)GridView1.Rows[i].FindControl("chkSel"); if (cbox.Checked == true) { if (string.IsNullOrEmpty(Ids)) { Ids = GridView1.DataKeys[i].Value.ToString(); } else { Ids += "," + GridView1.DataKeys[i].Value.ToString(); } } } if (!string.IsNullOrEmpty(Ids)) { B_ADZone.BatchPause(Ids); } this.RepNodeBind(); }
// 批量暂停 protected void BtnPause_Click(object sender, EventArgs e) { string Ids = Request.Form["idchk"]; if (!string.IsNullOrEmpty(Ids)) { B_ADZone.BatchPause(Ids); } DataBind(); }