aspose file tools
The moose likes Swing / AWT / SWT and the fly likes HELP!!!!! Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


JavaRanch » Java Forums » Java » Swing / AWT / SWT
Reply Bookmark "HELP!!!!!" Watch "HELP!!!!!" New topic
Author

HELP!!!!!

Dmitri Mayer
Greenhorn

Joined: Jan 05, 2005
Posts: 8
Once the string is received from the user, you need to check each character of that string to see if any of them is 0, 1, 2, 3, 4, 5, 6, 7, 8, 9. Then, if it is, you need to throw an appropriate exception. How can I check that is a number???
[ January 05, 2005: Message edited by: Dmitri Mayer ]
Michael Dunn
Ranch Hand

Joined: Jun 09, 2003
Posts: 4632
look up the String api for a method that converts the string to a character array,
then look up the Character api for a method that will do exactly what you want (in a loop of the character array)
Dmitri Mayer
Greenhorn

Joined: Jan 05, 2005
Posts: 8
thank you very very much
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: HELP!!!!!
 
Similar Threads
OOP-2
Test PersistenceContexts for equality
writing to a file
Java regex issue. Thank you in advance!
problem in cookie