I have an edit box that a user can input a starting number, hit return and
have it update formulas in other edit boxes.
After the updates, the user can use the numbers in the other edit boxes for
more formulations.
Now here is the problem.
The numbers in the updated edit boxes hold numbers that may contain commas
or periods for thousands separators, when these
are plugged back in the application for further formulations the number is
rejected saying it is not a valid floating point number.
I can parse it and remove the commas, but it really causes problems when in
other global numbering systems, the comma is the decimal place holder.
I need to use the floattostrf because each box has different precision and
decimal placements and may need to report back an exponent.
Is there a way that I can format this to accept a floating point that has a
thousand separator in it?
Example
ts := 1000 ;
editfah.text := floattostrf (ts, ffnumber, 9, 2) ;
Output is 1,000.00
Re-inputted the number chokes.
Thanks !
--------------------------
Jason R. Bennett
Director, Information Technologies
QualTek Molecular Laboratories
http://www.qmlabs.com
Regards,
Stuart
Jason Bennett wrote in message <01bded80$004105a0$18c847cf@default>...
var DelChar: char;
begin
DelChar := ThousandSeparator;
end;
This Works.
Spelling was a bit off.
Also, check SysUtils source code for more info.
Phil
Try ThousandSeparator
^^
Cheers,
Carl
It is ThousandSeparator and is defined in SysUtils.
Mike Orriss (m...@3kcc.co.uk)
http://www.3kcc.co.uk/notetree.htm
Thank you everyone for your help.
-Jason
Jason Bennett <jben...@qmlabs.com> wrote in article
<01bdedb0$edace540$0dc847cf@default>...
> Thanks for the info.
>
> I tried to use the ThousandsSeparator as a variable, but it said it was
an