|
|
Re: The use of "java.awt.Canvas"
|
Posted: Feb 19, 2004 11:17 AM
|
|
Hi!
I think you get this error because you just type "new CanvasTest" in main, instead you should write the main method like this:
public static void main(String[] args){ CanvasTest c = new CanvasTest();
This main method will not have any compilererrors. Another thing that might be the cause for this error is that you should only use addNotify(); when you have like a frame as superclass. Besides these remarks everything looks fine to me. Be aware this might not solv you errormessage, but it sure will make the code more correct in syntax.
mrx out.
|
|