Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to fix rounding bug
Message
From
02/10/2007 14:14:33
Dragan Nedeljkovich (Online)
Now officially retired
Zrenjanin, Serbia
 
 
To
02/10/2007 14:08:49
General information
Forum:
Visual FoxPro
Category:
Troubleshooting
Environment versions
Visual FoxPro:
VFP 9 SP1
Miscellaneous
Thread ID:
01258001
Message ID:
01258024
Views:
27
>Thank you.
>I have used round( ...,2) in 150 places in my code and in reports.
>
>Should I re-write all my code and change all reports to use double rounding ?

No... write some code that'll do that for you. Open each report, drive through expr field, get a lcstr=strextract(expr, "round(", ",2)") case insensitive, if it returns non-empty, check for parentheses in it (i.e. see whether you haven't cut it in the wrong place), and then replace with strtran(expr, lcStr, "round("+lcstr+",4)").

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Previous
Reply
Map
View

Click here to load this message in the networking platform