i m using this code
protected void Page_Load(object sender, EventArgs e)
{
Button3.Attributes.Add("onclick", "javascript:return Confirmationbox()");
}
protected void Button3_Click(object sender, EventArgs e)
{
foreach (GridViewRow gvrow in GridView1.Rows)
{
CheckBox chkchild = (CheckBox)gvrow.FindControl("chkchild");
if (chkchild.Checked)
{
int usrid = Convert.ToInt32(GridView1.DataKeys[gvrow.RowIndex].Value);
SqlDataSource1.DeleteParameters["userid"].DefaultValue = usrid.ToString();
SqlDataSource1.Delete();
}
}
}