hi,
I am trying to edit the row in the grid view, where i have a radiobuttonlist with three radio buttons. radiobuttonlist should not be edited when we click on edit but should be displayed. I tried to find the control and give the property but I could find the control. please help me...
thanks in advance.
Loading

srinath133 reputationPosted May 11, 2010, 3:46 AM EDT
Dipa AhujaRank #1,168 · 1.5K reputationPosted May 11, 2010, 4:41 AM EDT
srinath133 reputationPosted May 14, 2010, 1:39 AM EDT
Actually, what i need to do is --
I have a gridview, in that I placed radiobuttonlist with three radio buttons and text box.
when I check the two radio buttons, the text should be enabled and for another radiobutton, textbox must be disabled.
I wrote the code but it's not working
protected void rblist11_SelectedIndexChanged(object sender, EventArgs e)
{
foreach (GridViewRow item in GridView1.Rows)
{
RadioButtonList rbl = item.FindControl("rblist11") as RadioButtonList;
TextBox txtamount = item.FindControl("TextBox3") as TextBox;
if (rbl.SelectedItem.Value == "0")
{
txtamount.Enabled = false;
}
else if ((rbl.SelectedItem.Value == "1") || (rbl.SelectedItem.Value == "2"))
{
txtamount.Enabled = true;
}
}
}
plz help me..
Dipa AhujaRank #1,168 · 1.5K reputationPosted May 14, 2010, 3:12 AM EDT