Fox and numeric conversions depending on locale

View: New views
2 Messages — Rating Filter:   Alert me  

Fox and numeric conversions depending on locale

by John Selverian :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I'm writing a program with some users in other countries.  I am trying to
get the program to use the correct number format.  If I change my windows
setting to german when I use the

setlocale(LC_ALL,"");

command in my program it correctly returns

setlocale returned 0x010c2498 "German_Germany.1252"

the problem is that I cannot enter a number like 3,1415 in a text box...it
does not accept the , as the decimal.  also, all outputted text is written
with a .

is there a way to fix this?  do I need to do something more?

thanks,

js





--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.


------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Foxgui-users mailing list
Foxgui-users@...
https://lists.sourceforge.net/lists/listinfo/foxgui-users

Re: Fox and numeric conversions depending on locale

by Jeroen van der Zijp :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On Monday 24 August 2009, John Selverian wrote:

> I'm writing a program with some users in other countries.  I am trying to
> get the program to use the correct number format.  If I change my windows
> setting to german when I use the
>
> setlocale(LC_ALL,"");
>
> command in my program it correctly returns
>
> setlocale returned 0x010c2498 "German_Germany.1252"
>
> the problem is that I cannot enter a number like 3,1415 in a text box...it
> does not accept the , as the decimal.  also, all outputted text is written
> with a .
>
> is there a way to fix this?  do I need to do something more?

The current implementation of numeric conversions in FOX do not yet support
locale settings.  Sorry!

The new class FXLocale will harbor those functions.



                                - Jeroen




--
+----------------------------------------------------------------------------+
| Copyright (C) 07:20 08/25/2009 Jeroen van der Zijp.   All Rights Reserved. |
+----------------------------------------------------------------------------+

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Foxgui-users mailing list
Foxgui-users@...
https://lists.sourceforge.net/lists/listinfo/foxgui-users