Problem with Euro convert in ASP

# Thread: Problem with Euro convert in ASP

1. Member
Join Date
Dec 1969
Posts
49

## Problem with Euro convert in ASP

Cheers Rhino<BR><BR>&#060;b&#062;IR£&#060;% =RS("product_price") %&#062; / € &#060;% =(RS("product_price")/(0.787564))%&#062;&#060;/b&#062;<BR><BR>This gives me the correct out put: IR£835 / € 1060.23129548837<BR><BR>How do I limit the euro number to 2 decimal places or no decimal places so it rounds it off to the nearest whole number.<BR><BR>Cheers Lads !! much appreciated

2. Rhino Guest

## RE: Problem with Euro convert in ASP

Good grief, you are dealing with monetary values, you can&#039;t just go rounding them all up to the nearest Euro ! Imagine what would happen if the banks did that !<BR><BR>Anyway, this should be what you need - it uses FormatNumber to return only the 1st 2 digits after the decimal:<BR><BR>&#060;b&#062;IR£&#060;% =RS("product_price") %&#062; / € &#060;% =FormatNumber(RS("product_price")/(0.787564),2)%&#062;&#060;/b&#062;<BR><BR>Good luck, only 1452 days left till E-day

3. Rhino Guest

## Whoops, that should be

152 days left NOT 1452 :)

4. Member
Join Date
Dec 1969
Posts
49

## Cheers Rhino ur Brilliant!!

Nice one buddy !!

#### Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts
•