FEARLESS_SHELL01
Grasshopper
package com.company;
import javax.swing.JOptionPane;
public class DialogInput Box {
public static void main (String [] args) {
String fname, mname, lname;
String outputStr;
fname = JOptionPane.showInputDialog ("Enter your First Name: ") ;
mname = JOptionPane.showInputDialog ("Enter your Middle Name: ") ;
lname = JOptionPane.showInputDialog ("Enter your Last Name: ") ;
outputStr = "First Name: "+ fname + "\n" + "Middle Name" + mname + "\n" +"Last Name" + lname ;
JOptionPane.showMessageDialog(null, outputStr, "Student Information");
JOptionPane.showMessageDialog("ERROR_MESSAGE");
System.exit (0);
}
}
import javax.swing.JOptionPane;
public class DialogInput Box {
public static void main (String [] args) {
String fname, mname, lname;
String outputStr;
fname = JOptionPane.showInputDialog ("Enter your First Name: ") ;
mname = JOptionPane.showInputDialog ("Enter your Middle Name: ") ;
lname = JOptionPane.showInputDialog ("Enter your Last Name: ") ;
outputStr = "First Name: "+ fname + "\n" + "Middle Name" + mname + "\n" +"Last Name" + lname ;
JOptionPane.showMessageDialog(null, outputStr, "Student Information");
JOptionPane.showMessageDialog("ERROR_MESSAGE");
System.exit (0);
}
}