Logo 
Search:

Java Forum

Ask Question   UnAnswered
Home » Forum » Java       RSS Feeds

radio button

  Asked By: Oscar    Date: Nov 14    Category: Java    Views: 588
  

what would be the java code to create 2 simple radio buttons? "VOTE FOR BUSH"
and " VOTE FOR KERRY"

Share: 

 

4 Answers Found

 
Answer #1    Answered By: Stacie Martin     Answered On: Nov 14

JRadioButton b1 = new JRadioButton("VOTE FOR BUSH");
JRadioButton b2 = new JRadioButton("VOTE FOR KERRY");

ButtonGroup bg = new ButtonGroup();
bg.add(b1);
bg.add(b2);

 
Answer #2    Answered By: Adali Fischer     Answered On: Nov 14

This was very helpful! Please send the rest of code  including counter and
display too.

 
Answer #3    Answered By: Olga Kates     Answered On: Nov 14

Do you want this on a web page?

 
Answer #4    Answered By: Milind Mishra     Answered On: Nov 14

Yes......................................

 
Didn't find what you were looking for? Find more on radio button Or get search suggestion and latest updates.




Tagged: