Getting SelectedValue from RadioButtonList using javascript

Discussion in 'ASP .Net Web Controls' started by pierre@globalkinetic.net, Mar 11, 2005.

  1. Guest

    Hi,

    Can anyone tell me how to retreive the SelectedValue from a
    RadioButtonList, using javavscript.

    Here is my code:

    <ASP:RADIOBUTTONLIST id="optOption" runat="server"
    ONCLICK="javascript:alert(document.all.optOption.selectedItem);"></ASP:RADIOBUTTONLIST>

    This is not working. I am getting an error saying that
    'document.all.optOption.selectedItem is null or not an object'

    Thanks in advance,
    Pierre
    , Mar 11, 2005
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. thinkmast

    RadioButtonList SelectedValue

    thinkmast, May 7, 2006, in forum: .NET
    Replies:
    0
    Views:
    3,487
    thinkmast
    May 7, 2006
  2. Jeff
    Replies:
    2
    Views:
    2,284
  3. Arnold

    how to get selectedvalue of radiobuttonlist in Javascript?

    Arnold, Nov 12, 2006, in forum: ASP .Net Datagrid Control
    Replies:
    4
    Views:
    2,209
    Arnold
    Nov 12, 2006
  4. Replies:
    1
    Views:
    185
    nandha
    Mar 29, 2005
  5. Arnold
    Replies:
    6
    Views:
    370
    MikeS
    Nov 12, 2006
Loading...

Share This Page