[Lazarus] FormatFloat('#,##.00', -1) -> .-1,00
Werner Pamler
werner.pamler at freenet.de
Mon Sep 7 17:14:07 CEST 2015
> the function FormatFloat delivers a bad formatted negative value
> with(!) the dot from ThousandSeparator.
>
> In sysint.inc i found:
>
> { Character that is put every 3 numbers in a currency }
> ThousandSeparator : Char absolute
> DefaultFormatSettings.ThousandSeparator *deprecated*;
The format '#,##0.00' means: Format the number with two decimal places,
even if it is an integer. Replace the dot by
DefaultFormatSettings.DecimalSeparator. If the number is greater than
1000 (or less than -1000) add a thousand separator, replace the comma by
the DefaultFormatSettings.ThousandSeparator. The '#' identifies optional
digits which will be shown only when needed. The '0' identifies digits
which will be shown even if the corresponding digit would be 0 (i.e. if
the format string were '0,000.00' then the number 12 would be displayed
as '0.012,00' if DecimalSeparator is '.' and ThousandSeparator is '.').
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20150907/b62eb850/attachment-0003.html>
More information about the Lazarus
mailing list