Get DataKey values in GridView RowCommand
pass the RowIndex via CommandArgument and use it to retrieve the DataKey value
string Department = grdDetailsinst.DataKeys[row.RowIndex]["Usertype"].ToString();
string userid = grdDetailsinst.DataKeys[row.RowIndex]["Intuserid"].ToString();
pass the RowIndex via CommandArgument and use it to retrieve the DataKey value
string Department = grdDetailsinst.DataKeys[row.RowIndex]["Usertype"].ToString();
string userid = grdDetailsinst.DataKeys[row.RowIndex]["Intuserid"].ToString();
Comments
Post a Comment