Neat trick to test out applets w/o the html page by placing applet tags in the source file.
(could also be placed in a txt file, but then that wouldn't be neat anymore...)
Java Code:
[B]/*
  <applet code="MyApplet.class" width="200" height="200">
  </applet>
*/[/B]
import javax.swing.*;

public class MyApplet extends JApplet{
  public void init(){
    add(new JButton("OK"));
  }
}
Java Code:
USAGE:
  [B]appletviewer MyApplet.java[/B]