Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How To Get Currency Format (from Windows Regional Setting) ?
Message
From
27/05/2008 08:55:51
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Title:
How To Get Currency Format (from Windows Regional Setting) ?
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows XP SP2
Miscellaneous
Thread ID:
01319630
Message ID:
01319630
Views:
73
I found the following code, but it returns nothing. Why?

DECLARE INTEGER GetCurrencyFormat IN "kernel32" ;
INTEGER Locale,;
INTEGER dwFlags,;
STRING lpValue,;
INTEGER lpFormat,;
STRING lpCurrencyStr,;
INTEGER cchCurrency

cBuffer=SPACE(255)
cValue = "12345.6"
nLocale = 1033
GetCurrencyFormat(nLocale, 0, cValue, 0, cBuffer, Len(cBuffer))

* cBuffer is terminated with CHR(0)
cBuffer = LEFT(cBuffer,AT(CHR(0),cBuffer)-1)
Marc Levesque
La Prairie, Quebec (CANADA)
marc.levesque@videotron.ca
Next
Reply
Map
View

Click here to load this message in the networking platform