• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • paul wheaton
  • Devaka Cooray
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Liutauras Vilda
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Piet Souris
Bartenders:
  • salvin francis
  • Mikalai Zaikin
  • Himai Minh

radio button

 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi
I have two radio button
1.radio buttion----- text box1
2 radio button ----- text box2
text box3

If I click radio button 1 then radio button 2 and (text box2&3) should be disabled.
If I click radio buttion2 then radio button 1 and(textbox1) should be diabled

PLS HELP ME IN THIS. IT IS URGENT
BYE.
 
Sheriff
Posts: 14691
16
Eclipse IDE VI Editor Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

If I click radio button 1 then radio button 2


How are you going to click radio2 if you disable it
I think you should disable only textboxes, not radio buttons.
 
pradeep ms
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi
yes satou. Pls to all.
I have two radio button
1.radio buttion----- text box1
2 radio button ----- text box2
text box3

If I click radio button 1 then radio button 2 and (text box2&3) should be disabled.
If I click radio buttion2 then (textbox1) should be diabled

PLS HELP ME IN THIS. IT IS URGENT
BYE.
 
author
Posts: 15385
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
NO ONE IS GOING TO WRITE THE CODE FOR A PERSON THAT DEMANDS IT AND USES CAPS AND DOES NOT KNOW HOW TO SPELL OUT FULL WORDS SO PEOPLE THAT DO NOT UNDERSTAND ENGLISHG THAT WELL WILL NOT BE ABLE TO READ.

Now since caps in this world of forums and IM means you are screaming, do you see the problem with the message I wrote above. Yes. Do you see a problem you have with your message?

You already have been warned about your name here on the ranch before with this thread: https://coderanch.com/t/118856/HTML-JavaScript/javascript-select-option. There aren't many rules that you need to worry about here on the Ranch, but one that we take very seriously regards the use of proper names. Please take a look at the JavaRanch Naming Policy and adjust your display name to match it.

In particular, your display name must be a first and a last name separated by a space character, and must not be obviously fictitious.

Please do not use IM lingo in our forum, please do not demand stuff. This forum is not a code generator for you. It is here to help you learn. Also you title of this post is not very helpfull. Radio Button tells me nothing!

I think you need to learn if statements and document.forms[0].elementName.disabled = "true|false";

Eric Pascarello
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE VI Editor Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
And I'm still asking : "How are you going to click radio2 if you disable it once ?"
You're second post doesn't answer that.
 
Ranch Hand
Posts: 256
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Handle the above in the on click of the radio buttons.
And yes satou is right, how will you click on radio2 once you have clicked on radio1 since it gets disabled.
anyway try the above and see if it works for you.
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic