radio button is not working

Posted by Sunitajadhav under ASP.NET on 12/14/2009 | Views : 8023 | Status : [Member] | Replies : 4
Hello friends,
I am giving some code in which radio button checked property is not working.Please give me some ideas.

<input type="radio" id="RBSuccessor" runat="server" name ="ActivityRelationGroup" value="S" checked="CHECKED" />Successor
<input type="radio" id="RBPredessor" runat="server" name ="ActivityRelationGroup" value="P" />Predessor


I got this error "Cannot create an object of type 'System.Boolean' from its string representation 'CHECKED' for the 'Checked' property."

Thanks




Responses

Posted by: Chikul on: 12/14/2009 [Member] Bronze

Up
0
Down
Hi Sunitajadhav,

Instead of "Checked" use "True" . It'll work.

<input type="radio" id="RBSuccessor" runat="server" name ="ActivityRelationGroup" value="S" checked="True" />Successor

<input type="radio" id="RBPredessor" runat="server" name ="ActivityRelationGroup" value="P" />Predessor

Regards,
Chikul

Sunitajadhav, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Sagarp on: 12/14/2009 [Member] Bronze

Up
0
Down
<INPUT TYPE=RADIO NAME="pizzasize" VALUE="S" >small<BR>
<INPUT TYPE=RADIO NAME="pizzasize" VALUE="M" CHECKED>medium<BR>
<INPUT TYPE=RADIO NAME="pizzasize" VALUE="L" >large<P>


Thanks
SagarP
http://www.emanonsolutions.net
http://emanonsolutions.blogspot.com/

Sunitajadhav, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Sunitajadhav on: 12/14/2009 [Member] Starter

Up
0
Down
Its working.
Thanks...........

Sunitajadhav, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Sagarp on: 12/14/2009 [Member] Bronze

Up
0
Down
i m sagar pardeshi ok,no thx

Thanks
SagarP
http://www.emanonsolutions.net
http://emanonsolutions.blogspot.com/

Sunitajadhav, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response