Search:

Type: Posts; User: Norm

Search: Search took 0.11 seconds.

  1. Replies
    28
    Views
    3,044

    Re: How to set a button event trigger?

    Can you explain what "doesn't work" means? Is the method called? Add a println() statement that prints out the value returned by the getSource() method to see what component is causing the event and...
  2. Replies
    28
    Views
    3,044

    Re: How to set a button event trigger?

    final means the variable's value can't be changed. The contents of the object can be changed.
  3. Replies
    28
    Views
    3,044

    Re: How to set a button event trigger?

    You need an action listener. See the tutorial: How to Write an Action Listener (The Java™ Tutorials > Creating a GUI With JFC/Swing > Writing Event Listeners)
Results 1 to 3 of 3