Which Option button was selected

Posted on 2007-10-09
Last Modified: 2012-05-05
<asp:RadioButton GroupName="plan" ID="RB3F3" runat="server" />
<asp:RadioButton GroupName="plan" ID="RB4F2" runat="server" />

In C#, how do I check which option was selected in the code-behind? thanks

Question by:MikeMCSD
    LVL 9

    Assisted Solution

    More or less:

    your code here
    else code here

    Sorry if the sytax is a little off... I write in VB.
    LVL 21

    Accepted Solution

    if (RB3F3.Checked)
    if (RB4F2.Checked)

    Even though they belong to the same group, they are two seperate controls and to get what is checked each has to be read seperately
    LVL 16

    Author Comment

    thanks guys . . I prefer VB too and using C# is a rude awakening.

    Featured Post

    IT, Stop Being Called Into Every Meeting

    Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

    Join & Write a Comment

    We all know that functional code is the leg that any good program stands on when it comes right down to it, however, if your program lacks a good user interface your product may not have the appeal needed to keep your customers happy. This issue can…
    Introduction Hi all and welcome to my first article on Experts Exchange. A while ago, someone asked me if i could do some tutorials on object oriented programming. I decided to do them on C#. Now you may ask me, why's that? Well, one of the re…
    Hi everyone! This is Experts Exchange customer support.  This quick video will show you how to change your primary email address.  If you have any questions, then please Write a Comment below!
    This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor ( If you're looking for how to monitor bandwidth using netflow or packet s…

    729 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    20 Experts available now in Live!

    Get 1:1 Help Now