Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Subtypes

Status
Not open for further replies.

Andy6666uk

Programmer
Jul 11, 2001
17
GB
Hi there

I am having trouble with some arithmetic e.g.:

2 / 60

which should give me:

0.033333333...

but the variant I get has the subtype Double:

3.33333333333333E-02

which is no good because I want to turn it into a string.

I don't want to convert to an integer, because of rounding up, do I need to convert to another subtype and if so which one?

thanks for your help, Andy
 
use FormatNumber(Expression [,NumDigitsAfterDecimal])

i=formatnumber(2/60,20)
Response.Write i
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top