Java JOptionPane show message dialog

Description

Java JOptionPane show message dialog


// Using JOptionPane to display multiple lines in a dialog box.
import javax.swing.JOptionPane; 

public class Main
{
   public static void main(String[] args)
   {/* w  ww .  j a  va 2  s  . c om*/
      // display a dialog with a message 
      JOptionPane.showMessageDialog(null, "Welcome to Java");
   } 
}



PreviousNext

Related