Listen to two JRadioButton + ons JButton to produce output
Listen to two JRadioButton + ons JButton to produce output
I am a beginner in Java ..
I am trying to write a code for a simple program
I will omit the details; I will focus here on the problem.
I have a simple interface
Two JRadioButton objects called even and odd
One JButton called generator
One JTextArea called txtArea
Depending on:
If the radio button even is selected and the button generator is clicked produces an output to the txtArea
If the other radio button odd is selected and the button generator is clicked produces a different output to the txtArea
How to link those together
give me the Outline
Code :
private class ButtonWatcher implements ActionListener
{
public void actionPerformed(ActionEvent a)
{
}
}
Re: Listen to two JRadioButton + ons JButton to produce output
:D I solved it myself ,, I don't need any help :D
@};-