• 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
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Solved : Java Radiobutton problem

 
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Solved it , Don't read this post
Found answer at http://wiki.netbeans.org/FaqFormRadioButtonGroup
Thank you

I'm using netbeans 7 to create a UI to connect MS Access database.
Currently I have problem with a Radio button I use to add Gender (M,F)
In my GUI both Male and Female can be selected at once. But
I need to avoid multi selections, So that only 1 Radio button can be use at
a time. Below I have posted appropriate parts of my code.

May this could be done changing button properties ?


Thank you very much for reading.
 
Marshal
Posts: 28193
95
Eclipse IDE Firefox Browser MySQL Database
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Here's the relevant Oracle tutorial: How to Use Buttons, Check Boxes, and Radio Buttons. Scroll down to the part about radio buttons to see how to make them be mutually exclusive.
 
Sander Silva
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Paul Clapham wrote:Here's the relevant Oracle tutorial: How to Use Buttons, Check Boxes, and Radio Buttons. Scroll down to the part about radio buttons to see how to make them be mutually exclusive.



Reply : Thank you!

I fount that ,

I need to create a ButtonGroup instance and add each radio button to it.
 
Paul Clapham
Marshal
Posts: 28193
95
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Sander Silva wrote:I need to create a ButtonGroup instance and add each radio button to it.



Glad you got it solved! (I was afraid you were going to ask "How do I do that in Netbeans"...)
 
Sander Silva
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Solved it ,
Found answer at http://wiki.netbeans.org/FaqFormRadioButtonGroup
Thank you
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic