private void BindControllerRepeater() { EmailRepository EmailControllerReb = new EmailRepository(); DataTable dataTable = EmailControllerReb.GetEmailAssignController(Convert.ToInt32(txtEmailId.Text)); RepeaterController.DataSource = dataTable; RepeaterController.DataBind(); }
protected void btnCancelAssign_Click(object sender, ImageClickEventArgs e) { EmailRepository EmailAssign = new EmailRepository(); DataTable con = EmailAssign.GetEmailAssignController(Convert.ToInt32(txtEmailId.Text)); DataTable users = EmailAssign.GetEmailAssignUsers(Convert.ToInt32(txtEmailId.Text)); if (con.Rows.Count == 0 && users.Rows.Count == 0) { EmailAssign.UpdateIsAssign(Convert.ToInt32(txtEmailId.Text), 0, 0); } else { int emailStatus = EmailAssign.GetStatus(Convert.ToInt32(txtEmailId.Text)); EmailAssign.UpdateIsAssign(Convert.ToInt32(txtEmailId.Text), 1, emailStatus); } Page.Response.Redirect(Page.Request.Url.ToString(), true); }