all groups > asp.net building controls > march 2005 >
You're in the

asp.net building controls

group:

Using Radio button in a Data Repeater


Using Radio button in a Data Repeater Samuel Ashley via .NET 247
3/31/2005 4:03:48 AM
asp.net building controls:
I want to use a radio button in a data repeater which will allow me to select only one item.
could somebody please help me. Thanks


--------------------------------
From: Samuel Ashley

-----------------------
Posted by a user from .NET 247 (http://www.dotnet247.com/)

Re: Using Radio button in a Data Repeater Rajesh C K R
3/31/2005 7:33:17 PM
One way is the following:

Inside the repeater (say for each item template), add a line

<input type="radio" name="mychk" value=<%#whatever%>>

Note that the above is NOT marked runat =server.

On the post back you can find which button was checked from Request["mychk"]

Hope this helps

Rajesh
http://www.sharpVoice.com



[quoted text, click to view]

AddThis Social Bookmark Button