This week's book giveaway is in the General Computing forum.
We're giving away four copies of Arduino in Action and have Martin Evans, Joshua Noble, and Jordan Hochenbaum on-line!
See this thread for details.
The moose likes Java in General and the fly likes Converting String value 2.0 into int Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


JavaRanch » Java Forums » Java » Java in General
Reply Bookmark "Converting String value 2.0 into int" Watch "Converting String value 2.0 into int" New topic
Author

Converting String value 2.0 into int

saumil baxi
Ranch Hand

Joined: Apr 18, 2008
Posts: 58
Hi ,
I have s String variable having value 2.0 I need to convert it into int.

The method i have used is :


Is there any straight forward implementation..

Thanks,
Saumil
Balasubramanian Chandrasekaran
Ranch Hand

Joined: Nov 28, 2007
Posts: 215

Just change your code like this
saumil baxi
Ranch Hand

Joined: Apr 18, 2008
Posts: 58
Thanks a lot
 
I agree. Here's the link: http://zeroturnaround.com/jrebel - it saves me about five hours per week
 
subject: Converting String value 2.0 into int
 
Similar Threads
I need help,a question about String objects!
overriding equals method in my class
the importance of wrappers
String Class Method
is there any way pass arguments to class method without overloading ?