🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.java.swing
Article #12151

Re: How to 'unite' 2 radio buttons

#12151
From: Anne Nortcliffe
Date: Thu, 18 Feb 1999 00:00
23 lines
1353 bytes
You need to add the radio buttons to a ButtonGroup, try this;
    First declare the variables;

    ButtonGroup but1=new ButtonGroup();
    JRadioButton jRadioButton1=new JRadioButton();
    JRadioButton jRadioButton2=new JRadioButton();

    then in the implentation....

    but1.add(jRadioButton1);
    but1.add(jRadioButton2);

    then just put the buttons where you want them....


C Javier Castro Pe�a wrote:

> I need to have 2 radio buttons, so only one can be clicked at a time.
> Jbuilder allows to put 2 separated radio buttons, how can I link them? I
> want to do something such as the checkbox panel from jbcl, but
> lightweight (that's why I am not using it).
>
> (please, forward answer to jcaspen@iname.com)
Technical Details
Message-ID: <36CBFA51.2129E507@sheffield.ac.uk>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail
References: <36C4DB52.12499D7C@ittc.ukans.edu>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII
X-Google-Thread: 111d45,889acf4e0eb535e8
X-Google-Attributes: gid111d45,public
From: Anne Nortcliffe <cop94aln@sheffield.ac.uk>
Subject: Re: How to 'unite' 2 radio buttons
Date: 1999/02/18
Message-ID: <36CBFA51.2129E507@sheffield.ac.uk>
X-Deja-AN: 445663187
Content-Transfer-Encoding: 8bit
References: <36C4DB52.12499D7C@ittc.ukans.edu>
To: "C Javier Castro Pe�a" <jcaspen@ittc.ukans.edu>
Content-Type: text/plain; charset=iso-8859-1
Organization: Another Netscape Collabra Server User
Mime-Version: 1.0
Newsgroups: borland.public.jbuilder.java.swing