Ejemplo n.º 1
0
 protected void btnDeleteConfirm_Click(object sender, EventArgs e)
 {
     SqlDataSource7.DeleteCommandType = SqlDataSourceCommandType.Text;
     SqlDataSource7.DeleteCommand     = "DELETE FROM dbo.profile WHERE (Pro_Id = @Pro_Id)";
     SqlDataSource7.DeleteParameters.Add("Pro_Id", Request.QueryString["Pro_Id"]);
     SqlDataSource7.Delete();
     Response.Redirect("Home.aspx");
 }
Ejemplo n.º 2
0
 protected void GridView2_RowDeleting(object sender, GridViewDeleteEventArgs e)
 {
     SqlDataSource7.Delete();
     GridView2.DataBind();
 }