0
Hi,
i attached my source code with this. Instead of Command button, i have used link button. In code-behind, use link button Event handler , to do the task that you want.
In that code, I retrieved grid row index based on link button click. so, based on row index, you can perform difference tasks.
0
Hi Anele,
you have use the Rowcommand event of the grid like this:
protected void GridView1_RowCommand(object sender,
GridViewCommandEventArgs e)
{
if (e.CommandName == "btnMonday")
{
// Retrieve the row index stored in the
// CommandArgument property.
int index = Convert.ToInt32(e.CommandArgument);
// Retrieve the row that contains the button
// from the Rows collection.
GridViewRow row = GridView1.Rows[index];
// Add code here
}
}
Please do not forget to mark "Accepted Answer".