I've used template field approach
i want to fetch its value from c#(beckend)
I've already tried
{
GridViewRow row = grdPaymentrelease.Rows(e.RowIndex);
value = ((TextBox)row.FindControl("STATUS")).Text.ToString().Trim();
}
}
on rowdatabound function with e as System.Web.UI.WebControls.GridViewRowEventArgs
giving error - RowIndex is not a member of e
instead I also tried e As GridViewUpdateEventArgs
its asking to make new function
Help!


Gajendra JangidRank #157 · 14.9K reputationPosted May 28, 2019, 8:01 PM EDT
Bhavleen Singh197 reputationPosted May 28, 2019, 11:37 PM EDT
Gajendra JangidRank #157 · 14.9K reputationPosted May 28, 2019, 11:42 PM EDT
Bhavleen Singh197 reputationPosted May 28, 2019, 11:53 PM EDT
{
string Status;
int i;
GridViewRow di = grd.Rows(i);
foreach (var di in grd.Rows)
{
Status = (Label)di.Cells(15).FindControl("lblStatus").Text;
CheckBox chkbx = (CheckBox)grdPaymentrelease..Rows(i).FindControl("CheckStatus");
if (Status == "Y")
chkbx.Visible = true;
else
chkbx.Visible = false;
}
}
its not giving error but its diabling only one checkbox instead of multiple