aspose file tools*
The moose likes Beginning Java and the fly likes Java Input Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Reply locked New topic
Author

Java Input

David Lafo
Greenhorn

Joined: Oct 28, 2003
Posts: 3
Hi, im trying to write a java program that allows for conversions to different bases. The conversions aren't the hard part its the input that is giving me trouble. I can only use System.in.read for my input. I was hoping someone could help me and show me how this is done because when i input the number i get the ascii value and i dont know how to convert it from a char to an int. i need up to a five digit number for my input. I was hoping someone could teach me how to do the input properly by casting the number from a char to an int after the input. This would be greatly apprecieated and I thank in advance anyone who can help me with this problem. As you can probably tell im relatively new to java so in other words could you dumb it down for me .
Thankyou
David
Jason Menard
Sheriff

Joined: Nov 09, 2000
Posts: 6450
Hi and welcome to JavaRanch. For future reference, please avoid cross-posting the same question to multiple forums. This question has been answered in the duplicate thread in I/O, so I'm going to close this one. Please direct further discussion there.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Java Input