• Post Reply Bookmark Topic Watch Topic
  • New Topic

Netbeans 7.0.1 questions

 
Adrian Jakubas
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I type this out of Sams Teach Yourself Java 6 into netbeans 7.0.1

and I get this after build successful

Error: Main method not found in class volcanorobot.VolcanoRobot, please define the main method as:
public static void main(String[] args)
Java Result: 1
 
Kondwani Chipeta
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
As the error message says, there is no method so the VM can not find an entry point to begin execution of your program. Try adding one and see what happens.
Remember a class can compile if it doesn't have a main method but execution requires a main method.
 
Kondwani Chipeta
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
And welcome to the Ranch Adrian.
 
my overalls have superpowers - they repel people who think fashion is important. Tiny ad:
the new thread boost feature brings a LOT of attention to your favorite threads
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!