I just copied your program and added the System as you were advised -- the
program looks like this:
public class TextPadTest{
public TextPadTest(){System.out.println ("this is a test");}
public static void main(String[] args)
{
new TextPadTest();
}
}
This compiles and runs without problems and the results are
this is a test
written to standard out. Clearly something else is wrong. How are
you invoking the call? It should be something like
java TextPadTest
If it's something other than that, you need to make sure that you're calling
the class where it exists (that is, the .class file, not the .java file).
If that's
what you've called, make sure that your system can find the class -- you
might have a problem with your classpath.