General information
Category:
Coding, syntax & commands
Hello Nadya.
>> I've checked old messages, but didn't find a solution for this problem: I need to find out the number of digits in a number. <<
Just to give you one more idea, if you have FoxTools loaded, you can use StrFilter() like so:
LEN( STRFILTER( TRANSFORM( MyNumericValue ), "0123456789" ) )
But this solution has the same limitation as the one Vlas suggested using CHRTRAN.
>> Say, I have 12.3456000 - the number of digits should be seven. <<
By my reckoning, there are 9 digits there if you include the trailing zero's. Or did you really mean the number of digits to the right of the decimal point? If this is the case, something like this should work:
LEN( GETWORDNUM( TRANSFORM( MyNumericValue ), 2, '.' ) )
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only