Cannot find symbol error
First of all I want to say I am a complete nub to this so sorry if it's some dumb mistake, right now I am trying to make a small applet to check for keyboard input, I have been following the tutorial but it seems to think that i already know how to begin and end the applet because it just gave me the keyDown method and I have had to fill in the rest, so now I am getting the following error message when I try to compile:
keyboard.java:13:cannot find symbol
symbol : variable message
location: class variable
message = "value = " + key;
^
1 error
Here is my code:
import java.awt.Graphics.*;
import java.awt.*;
publicclass Keyboard{
publicstaticvoid main(String args[]){}
int key;
publicboolean keyDown(Event E,int key)
{
message ="value = " + key;
returntrue;
}
publicvoid paint(Graphics g)
{
g.drawString("key ="+key,10,20);
}
}
Any help would be appreciated, thanks.

