protected void GridView2_RowCommand(object sender, GridViewCommandEventArgs e)
{
if (e.CommandName == "Select")
{
/* use this format or one below
int index = Convert.ToInt32(e.CommandArgument);
GridViewRow selectedRow = GridView2.Rows[index];
TableCell tcFNumber = selectedRow.Cells[0];
String Fnumber = tcFNumber.Text;
*/
DataRowView rowView = (DataRowView)e.Row.DataItem;
String Fnumber = rowView["Fnumber"].ToString();
}
}
|