Re: java.lang errors
- From: "fuzzybr80" <fuzzybr80@xxxxxxxxx>
- Date: 30 Mar 2006 18:27:09 -0800
Integer.parseInt returns this NumberFormatException error if the input
is not numeric.
"Enter Length" which means the user has not entered a proper number.From the error it appears that enterLength.getText() returns the string
You can either check if the string is numeric first, or enclose it in a
try{} catch{} block with a handler to catch NumberFormatExceptions.
.
- References:
- java.lang errors
- From: janicethorne via JavaKB.com
- java.lang errors
- Prev by Date: Re: File IO -- Reading Config Files Easily
- Next by Date: Re: Where do you put the javax pacakages?
- Previous by thread: java.lang errors
- Index(es):