select only one option

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • krishnaneeraja
    New Member
    • Mar 2008
    • 21

    select only one option

    Hi
    i have one problem plz solve this.radiobutto n and textbox is there.if we select radio button disable textbox and if we want to enter text in textbox then disable radiobutton.plz giv me code for this.


    thanks
    Neeraja.
  • indianmaestro
    New Member
    • Mar 2008
    • 16

    #2
    wite code in radiobutton_che ckedchanged event
    {
    if(radio1.check ed==true)
    {
    textbox1.anbled ==false;
    }
    else
    {
    textbox1.anable d==false;
    }

    }
    this may help you

    Comment

    • saran23
      New Member
      • Mar 2008
      • 28

      #3
      Originally posted by krishnaneeraja
      Hi
      i have one problem plz solve this.radiobutto n and textbox is there.if we select radio button disable textbox and if we want to enter text in textbox then disable radiobutton.plz giv me code for this.


      thanks
      Neeraja.
      Hi Neeraja,

      Set autopostback property of the radio button to true, then in the OnSelected event of the radio button make the textbox disable.
      Do the reverse for the enabling purpose., but check if the radio button is selected in the onselected event, If its checked then enable the textbox.

      Try this, Dont ask for prewritten code, it will no way help u in future..

      its a simple one, try, if ur not successfull i can help u further.

      Thanks
      Saravanan

      Comment

      Working...