View Single Post
  #2 (permalink)  
Old 07-30-2007, 06:24 PM
brianhks brianhks is offline
Senior Member
 
Join Date: Jul 2007
Posts: 134
brianhks will become famous soon enough
You have defined the text() method inside of the main method. I would also recommend using a consistent style. Your errors will be easier to see if you do.

For example here is your code but formated differently
Code:
public class HelloWorld { public static void main(String[] args) { public void text() { sh.text("hello"); } } }
Now it is easier to see that text() is inside main.
Reply With Quote