CodeVerge.Net Beta


   Item Entry   Register  Login  
Microsoft News
Asp.Net Forums
IBM Software
Borland Forums
Adobe Forums
Novell Forums




Can Reply:  No Members Can Edit: No Online: Yes
Zone: > Asp.Net Forum > general_asp.net.getting_started Tags:
Item Type: Date Entered: 2/1/2005 12:03:20 PM Date Modified: Subscribers: 0 Subscribe Alert
Rate It:
NR
XPoints: N/A Replies: 3 Views: 31 Favorited: 0 Favorite
4 Items, 1 Pages 1 |< << Go >> >|
"mtait" <>
NewsGroup User
Retrieving values from a dynamic radiobuttonlist2/1/2005 12:03:20 PM

0

Hi - I'm trying to do a dynamic survey app - and am adding RadioButtonList controls for each of the possible questions.

I can iterate through these as below, but how do I get the value of the selected item in the radio button list?

Thanks for any help,

Mark


Sub findAnswers(byval parent as control)
Dim c as control
for each c in parent.controls
if c.gettype() is gettype(RadioButtonList) then
'''found one
end if

if c.HasControls Then
findAnswers(c)
end if
Next
End Sub
"chuck.boyer" <
NewsGroup User
Re: Retrieving values from a dynamic radiobuttonlist2/1/2005 3:00:16 PM

0

This is for a checkbox list...but the concept should apply


For intCounter = 0 To myCheckList.Items.Count - 1
If myCheckList.Items(intCounter).Selected Then
myArrayList.Add(myCheckList.Items(intCounter).Value)
End If
Next

Chuck Boyer, MCSD .NET
Director of Production and Development
Edge Media Design
"mtait" <>
NewsGroup User
Re: Retrieving values from a dynamic radiobuttonlist2/1/2005 9:23:10 PM

0

Hi - thanks Chuck - where I'm stuck is where to read the value of the radiobuttonlist when I'm searching for it through the page (ie. I don't know what the name of it is yet, but have to change the c.gettype() into something like c.gettype.selectedvalue (that just doesn't work).

Thanks again,

Mark
"mxmissile" <>
NewsGroup User
Re: Retrieving values from a dynamic radiobuttonlist2/1/2005 11:46:20 PM

0

if(c.GetType() == typeof(RadioButtonList))

{
RadioButtonList rbl = (RadioButtonList) c;
//TODO found one stuff
}
Sorry my VB is not upto snuff...



http://www.heliosfx.com
4 Items, 1 Pages 1 |< << Go >> >|


Free Download:













open outlook email from asp.net page

find the duplicate string from a text file

vs 2005 pro upgrade from vs.net 2003 academic edition?

asp.net 2.0 directory structure

what's the right control for making a forum?

iis give error 405 resource not allowed

how to add time more than a day

setting up html tags declaratively

passing a value from one page to the next

key value pairs question

timestamps and sql stored procedures

unrecognized configuration section 'trace'

best online asp.net course

connectionsstring in asp.net 2.0

code works on local - not on net

cookie

postnotcashed

how do i get the "middle" dateformat?

media player on a web page

catch exceptions in asp.net 2.0 threads outside of the request thread

user control with dropdownlist - adding onselectedindexchanged

postback question

not all code paths return a value

customizing [autopostback] feature for dropdown control

resize a window

layout relative or absolute?

programatically login to a site and access pages

capturing jpg's from mpg file with code

system.web.ui.literalcontrol

moving/publishing files onto another site

need help bad!!! -> user control stopped working

placing a gridview or table view behind a button.

email always going in spam

redirect problem

private structure not populating ??

ecommerce template

getting and setting a class property?

input string not in a correct format. please help am stuck.

configuring asp.net framework v 1.1

using 3rd party dll

excel spread sheet

how do i progmatically go back to previous page

emailing webform error

barcdode validation

not reading web.config?

howto: close a child window and refresh parent window upon onclick event

dynamically creating divs within another div

cannot view form in visual studio.net after editing through frontpage 2003

syntax error in update statement

netscape, opera, mozilla, and macs

   
  Privacy | Contact Us
All Times Are GMT