Help with decimals numbers.
Kenneth Brody
kenbrody at spamcop.net
Wed Jan 29 08:45:42 PST 2014
On 1/29/2014 11:18 AM, Kroboth, Joe wrote:
> I have a report that I need to print some numbers. I always need to
> print to the hundredths unless the number go out beyond the hundredths
> then I need to print that number. The number would only ever go out to
> the 10 thousandths.
>
> Examples.
>
> 100 -> 100.00
>
> 100.1 -> 100.10
>
> 100.11-> 100.11
>
> 100.111->100.111
>
> 100.1111->100.1111
>
> .2 -> .20
>
> .02 -> .02
>
> .22-> .22
>
> .222->.222
>
> .2222->.2222
>
> Is there an easy way to do this? Edit maybe?
Assuming that the numbers will be left-justified:
["-"] [{N}] ( <.00>@ | "." ( <00>@ | N<0>@ | {N} ) )
Add a backslash at the start if they are to be right-justified.
If you need the decimals to be aligned, that will take some more work.
--
Kenneth Brody
More information about the Filepro-list
mailing list