A way to use a class as both an application and applet is to have the
main method call init... ie:
public class EitherWay extends javax.swing.JApplet {
public static void main (String[] args) {
EitherWay theApp = new EitherWay();
theApp.init();
}
public void init () {
// begin...
}
}
for more details about applets:
java.sun.com/docs/books/tutorial/applet/index.html