I'm having problems when I try to run my program. It compiles just fine, but when I go to run it I get this:
java.lang.NoSuchMethodError: mainHere is my program:
Exception in thread "main"
So after I got this I tried a much simpler 'Hello World' and I made sure it had a 'main' method.
import aLibrary.*;
public class Director {[indent] private SimpleWindow window;
private GrayCircle circle;
[/indent][indent] public Director() {[indent]window = new SimpleWindow();
circle = new GrayCircle();
circle.place(window);
window.repaint();
[/indent][/indent][indent] }
[/indent]}
This program works, but the other one doesn't. I replaced the 'public Director()' with 'public void main()' but I get the same error. Can anyone tell me how to fix this? The first program runs just fine on the Solaris Machines in class, just not at home.
public class HelloWorld {[indent] public static void main(String[] args) {
[/indent][indent][indent] System.out.println("Hello World!"😉;
[/indent][/indent][indent] }
[/indent]}