Please send questions to st10@humboldt.edu .
/**
 * TryJOptionPane
 * 
 * this very simple Java application simply demonstrates a nifty
 * component available in Swing: JOptionPane. It is lovely to use
 * as a dialog box.
 *
 * modified from Deitel and Deitel, "Java How to Program, 3rd edition,
 * p. 44
 *
 * modified by: Sharon M. Tuttle
 * last modified: 2-12-01
 **/

// need to import this when using Swing components;
import  javax.swing.*;

public class TryJOptionPane
{
        public static void main(String args[])
        {
		JOptionPane simpleDialog;

                // JOptionPane "allows you to easily display a dialog
                // box containing information", acc. to p. 43, Deitel and
                // Deitel
		simpleDialog = new JOptionPane();
                simpleDialog.showMessageDialog(null, "Welcome to\nSwing!");

                // acc to Deitel and Deitel, p. 46, "This line is required in
                // any application that displays a graphical user interface
                // to terminate the application."
                System.exit(0);         // terminate the program
        }
}