Presentation is loading. Please wait.

Presentation is loading. Please wait.

By: Stag and Fish; Party Animals.  Radio buttons are a way of letting users choose only one option of a list.

Similar presentations


Presentation on theme: "By: Stag and Fish; Party Animals.  Radio buttons are a way of letting users choose only one option of a list."— Presentation transcript:

1 By: Stag and Fish; Party Animals

2  Radio buttons are a way of letting users choose only one option of a list

3  Uses:  Surveys  Multiple choice questions  terms of service

4  They are created by implementing `JRadioButton` and grouping the buttons into a `ButtonGroup` public class Demo extends JPanel implements ActionListener { //Create a set of private reusable variables private String button1 = “Choice 1"; public Demo () { super(new BorderLayout()); //I have no idea what this does //Create Choice 1 JRadioButton button1 = new JRadioButton(Choice 1);

5  Check boxes are a way to allow users to select multiple options from a list

6  Uses:  Surveys with many applicable choices  Select all that apply  Choosing items from a list

7  Check boxes are created using JCheckBox items with unique names public class Checkboxes extends JPanel implements ItemListener { private JCheckBox b1; public Checkboxes() { super(new BorderLayout()); //This is a mystery //Create the check boxes. b1 = new JCheckBox("Do not uncheck!"); b1.setSelected( true);

8  Java Docs


Download ppt "By: Stag and Fish; Party Animals.  Radio buttons are a way of letting users choose only one option of a list."

Similar presentations


Ads by Google