Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Determining the number of decimal places of a variable?
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00759689
Message ID:
00759704
Views:
18
>Thanks a bunch Fred! You are the man!
>
>That made my day.
>
>> You could do:
>
>> cN = ALLTRIM(PADR(n,20))
>> nDecimal = RAT(".",cN)

Whoops, not quite, Rich.

It should be:
nDecimal = LEN(cN)-RAT(".",cN)
Fred
Microsoft Visual FoxPro MVP

foxcentral.net
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform