How to delete a row from DataGridView by clicking on delete hyperlink.Currently, the record is deleted by selecting the entire row. but I need to delete the row only upon clicking on ‘Delete’ link button.The following code is used to remove the row upon selecting the row.Please help me how to remove the row upon clicking on Delete Link(Not selecting the Row).
foreach (DataGridViewRow row in datagvRelation.SelectedRows)
{
datagvRelation.Rows.Remove(datagvRelation.CurrentRow);
}
Here you can replace zero with your columnindex containing the link…