The variable t must be given the address of a textfield. See how you did it in the Constructor.
Type: Posts; User: Norm
The variable t must be given the address of a textfield. See how you did it in the Constructor.
Well not really. t is a variable that refers/points to a text field. It really is a pointer because you get the NullPointerException when you try to use it when its null. It is possible to have many...
x = 4; // Give the value 4 to the variable x
In your program we were talking about the variable t.
Remember:
The compiler is finding it, otherwise there would be an error message about missing definition.
The one its using at that point in the code has a null value when the code is executed.
Where does...
What text book are you using?
I bet you could get a definition using Google.
Nothing to do with coordinates.
What is the scope of the t variable assigned a value in the Constructor?
Or instead of using anonymous classes you could define the classes A, B, etc to implement the ActionListener interface and put the actionPerformed() method in them.