File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes HTML, CSS and JavaScript and the fly likes possible we can turn Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Reply Bookmark "possible we can turn "0.5" to "1/2"" Watch "possible we can turn "0.5" to "1/2"" New topic
Author

possible we can turn "0.5" to "1/2"

Nakata kokuyo
Ranch Hand

Joined: Apr 13, 2005
Posts: 437
good day to all,

is it possible when a user enter "13.5" , then we convert it into "13 1/2" ?

thank you very much for guidance
Eric Pascarello
author
Rancher

Joined: Nov 08, 2001
Posts: 15357
    
    6
If you code a function that does it.

Eric
Nakata kokuyo
Ranch Hand

Joined: Apr 13, 2005
Posts: 437
thanks for reply Eric Pascarello ,

in function , do we replace the value .5 to 1/2 or we have special function to insert the special character "1/2" ?
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 56178
    
  13

No, there are no special functions. This is something you'll have to come up with an alogrithm for on your own.


[Smart Questions] [JSP FAQ] [Books by Bear] [Bear's FrontMan] [About Bear]
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: possible we can turn "0.5" to "1/2"
 
Similar Threads
ResultSet.close()
What is the best third party print API available with robust print capabilities?
JSP
JCAPS and JavaFX
Occasional inaccuracy in addition calculations. Why?