c# - About RadioButton CheckedChanged event -


For example, when I first select the radio button (last name), then I am using the same text box. I search for the client's last name, when I select the second radio button (doctor code), I search by code and likewise, how can I manage or handle exceptions when, for example, if the user "date" Search from "and send a string type?

I am using C # 3.5 - asp.net

I would like to create it with regular expressions and add it to the radio button, so that when the user changes the radio, So it can just type some characters in option A, option B and others, and just date in the OptionC ... (regular expression)

thanks in advance

If you are using the ASP Web Control Redbotton list Programmed you can make a lot of changes when a postback. You can set the attribute for selectIndexChanged, so whenever they are changed, this is the reason for a postback and then whatever you can (verification). Ex:

  and asp: radio buttonList id = "radio1" runat = "server" autoPostBack = "true" cellSpacing = "20" repeat column = "3" repeat = "horizontal" repeat = "Table" Text Aligns = "Correct" On-Sylased Index changed = "Radio Selective Induct Change" & gt; & Lt; Asp: ListItem text = "10pt" value = "itsMe" /> & Lt; Asp: ListItem text = "14pt" value = "itsYou" /> & Lt; Asp: ListItem text = "16pt" value = "neither" /> & Lt; / ASP: RadioButtonList & gt;  

You must have on the server by calling the name of

  protected void radio_electedIndexChanged (Object Sender, EventArgs) Id // example if (radio 1. selected i.Tem.Value == "(whatever you want to test)"}  

Comments