Java Tutorial 13: Adding Action Listener in Java

Loading...

Sign in or sign up now!
Alert icon
Upgrade to the latest Flash Player for improved playback performance. Upgrade now or more info.
6,365
Loading...
Alert icon
Sign in or sign up now!
Alert icon

Uploaded by on Feb 10, 2011

In this tutorial, I will teach you how to add Action Listener in Java.

Please Rate, Comment and Subscribe.

Category:

Education

Tags:

License:

Standard YouTube License

  • likes, 0 dislikes

Link to this comment:

Share to:

Uploader Comments (Creativitytuts)

  • I noticed in another video, you import java.awt.*;

    When I tried to write this program, I imported java.awt.*; I kept getting errors until I changed it to java.awt.event.*; Do you know why that is?

  • @moufpuncha : When you are adding Action Listener you need to import Java.awt.event.*; otherwise it will give an error message.

    Java.awt.* library is only to create GUI.

Video Responses

see all

All Comments (6)

Sign In or Sign Up now to post a comment!
  • Brilliant tutorial, helped me understand so much, thank you! Could you tell me the advantage of putting all your code in the class constructor? (Big time newbie here! Sorry for the probably obvious question...)

  • thanks for uploading tutorials!

    it really helped me to understand the action listener...

    im new at java so i'll probably be watching more of your videos

  • I'm looking for help so my GUI will use the the information in the JTextField to get my answer and display it using that same GUI

    I got the frame and buttons and listeners ready! but i cant get it to use the information on JTextfield my program opens another JOtionPane box to ask me to imput that information ( i know i did that through import JOptionPane ) when i press the buttons

Loading...

Alert icon
0 / 00Unsaved Playlist Return to active list
    1. Your queue is empty. Add videos to your queue using this button:
      or sign in to load a different list.
    Loading...Loading...Saving...
    • Clear all videos from this list
    • Learn more