This section illustrates you how to create a Check Box component in Java Swing.
In this section, you can learn simply creating the Check Box in Java Swing. Check Boxes are created in swing by creating the instance of the JCheckBox class using it's constructor which contains the string which has to be shown beside the check box on the frame or window like this:
This is written like:
JCheckBox chk = new JCheckBox("This is the Check Box");
This component of the javax.swing.*; is added to the frame using the add(component) method of the JFrame class.
Here is the code of the program:
Rs. 20,000 US$ 300
Today: Rs. 10,000 US$150
Course Duration: 30 hrs
Posted on: April 14, 2007 If you enjoyed this post then why not add us on Google+? Add us to your Circles