473,385 Members | 2,274 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Repeter

hi i am using a repeter to show some option in a form. this option
are
radio buttons. the item template for my repeter loks like this
<ItemTemplate>
<input type="radio" runat="server"
id="membership"
name="membership" value='<%#
DataBinder.Eval
(Container.DataItem,
"Name")%>'>
<%# DataBinder.Eval(Container.DataItem,
"Name")%>
<br>
</ItemTemplate>

every thing displays great and when i look a the html generated the
radios have their "value"property set correctly.
my question is how do i get the value of the radiobutton that was
selected?
has any one done this. if so please help :!:

Nov 16 '05 #1
3 1662
Since no-one has answered I'd guess this question is either irrelevant, doesn't make sense or posted to the wrong group.
"julk" wrote:
hi i am using a repeter to show some option in a form. this option
are
radio buttons. the item template for my repeter loks like this
<ItemTemplate>
<input type="radio" runat="server"
id="membership"
name="membership" value='<%#
DataBinder.Eval
(Container.DataItem,
"Name")%>'>
<%# DataBinder.Eval(Container.DataItem,
"Name")%>
<br>
</ItemTemplate>

every thing displays great and when i look a the html generated the
radios have their "value"property set correctly.
my question is how do i get the value of the radiobutton that was
selected?
has any one done this. if so please help :!:

Nov 16 '05 #2
in answer to your question I think you may need to invoke Javascript in order to get that. If the selection of the radio buttons doesn't cause a postback , then you'll need to get the information to the server somehow - try the doPostback method (you call it on an invisible control)
"julk" wrote:
hi i am using a repeter to show some option in a form. this option
are
radio buttons. the item template for my repeter loks like this
<ItemTemplate>
<input type="radio" runat="server"
id="membership"
name="membership" value='<%#
DataBinder.Eval
(Container.DataItem,
"Name")%>'>
<%# DataBinder.Eval(Container.DataItem,
"Name")%>
<br>
</ItemTemplate>

every thing displays great and when i look a the html generated the
radios have their "value"property set correctly.
my question is how do i get the value of the radiobutton that was
selected?
has any one done this. if so please help :!:

Nov 16 '05 #3
If you want to capture the selected value as soon as the user changes
the value, use a WebControls.RadioButton, set AutoPostBack to true,
and assign an event handler to CheckChanged event (just double click
in the properties window).

Another option is to let the user adjust the selections for multiple
rows and hit a submit button. In this case you can loop through the
repeater items on the server and extract the value for each button.

I have an example of looping through a repeater to get the value of
TextBox controls towards the end of the following article, so this
should provide some insight:

http://odetocode.com/Articles/116.aspx

--
Scott
http://www.OdeToCode.com/blogs/scott/

On 11 Jul 2004 17:03:24 -0500,
cr*********@hotmail-dot-com.no-spam.invalid (julk) wrote:
hi i am using a repeter to show some option in a form. this option
are
radio buttons. the item template for my repeter loks like this
<ItemTemplate>
<input type="radio" runat="server"
id="membership"
name="membership" value='<%#
DataBinder.Eval
(Container.DataItem,
"Name")%>'>
<%# DataBinder.Eval(Container.DataItem,
"Name")%>
<br>
</ItemTemplate>

every thing displays great and when i look a the html generated the
radios have their "value"property set correctly.
my question is how do i get the value of the radiobutton that was
selected?
has any one done this. if so please help :!:


Nov 16 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: peterbe | last post by:
I want to match a word against a string such that 'peter' is found in "peter bengtsson" or " hey peter," or but in "thepeter bengtsson" or "hey peterbe," because the word has to stand on its own....
0
by: Pallavi Kulkarni. | last post by:
My page contains one repeter inside another repeater,As I have to display List of companies which I m getting thru Dataset And child companies will come inside their parent companies. Parent...
0
by: Curious George | last post by:
I get an error in the repeter on the DataBinder.Eval(Container.DataItem, "sec_alias") call. When in the debuger I can see the data but is is not displayed. In VB is used 'Filter out...
3
by: Eric Newton | last post by:
Given databinding an array of System.Version types: Given that "SomeObject" type has a Version property: public class SomeObject { public Version Version { get; } public string Description {...
1
by: Manish Songar via .NET 247 | last post by:
(Type your message here) I am using asp.net. I am not storing image in sql server.I store all the image in one folder. I want to access image from that folder to my client machine. Images folder...
1
by: Manish Songar via .NET 247 | last post by:
I am using asp.net. I am not storing image in sql server.I store all the image in one folder. I want to access image from that folder to my client machine. Images folder (\Orchid_Image) store in...
0
by: alok.gemini | last post by:
Problem - i am using the nested repeter . the second repeter is binding on the time of event (onitemdatabind ) which is in first repeter . but my second repeter is not bind up. Do u Have Any Idea.
0
by: satishambition | last post by:
Hay frds How can I Bound One repeter control In The item list Of another repeter control regards satish
5
by: kunjal | last post by:
im trying to change the color of the link button which is dynamically generated in a repeater once it is clicked. but the thing isnt working .nor the jscript. and tell me how to call my javascript...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.