protected void gv_viewRequest_RowDeleting(object sender, GridViewDeleteEventArgs e) { int connId = Convert.ToInt32(gv_viewRequest.DataKeys[e.RowIndex].Values[0]); ConnectionBLL.ModifyConnectionRejected(connId); ConnectionBLL.DeleteConnectionById(connId); Response.Redirect("~/Pages/User/Connections.aspx"); }