guys what is the difference between JButton and JToggleButton?

Check the API reference. A JToggleButton is "An implementation of a two-state button. The JRadioButton and JCheckBox classes are subclasses of this class"
A JButton is "An implementation of a "push" button."

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.