Okay, so i've been trying to create a gui that will process my method. For the most part it works, however there are a few hiccups.
I want the dialog box to pop back up after the person hits okay for the second time (i.e. after the method runs)
Also, whenever I use the cancel button I get
here's my code thus far:Code:Exception in thread "main" java.lang.NumberFormatException: null
at java.lang.Integer.parseInt(Unknown Source)
at java.lang.Integer.parseInt(Unknown Source)
at NumbersToWords.main(NumbersToWords.java:11)
Code:public static void main(String[] args) {
// TODO Auto-generated method stub
String entry;
entry = JOptionPane.showInputDialog(null, "Input numerical number:");
int number = Integer.parseInt(entry);
JOptionPane.showMessageDialog(null,input(number));
System.exit(0);
}
