Hi,
though WinDev Help says that the comma symbol in display masks will be replaced automatically by the decimal separator currently active in Windows, there may be a need to get the current decimal separator from Windows:
PROCEDURE DecimalSeparator()
MAX_BUFFER_SIZE is short int=100
LOCALE_USER_DEFAULT is long int=1024
LOCALE_SMONDECIMALSEP is long int=22
mApiReturn is long int
mBuffer is string
mBufferSize is long int
mBuffer = RepeatString(Charact(0),MAX_BUFFER_SIZE)
mBufferSize = MAX_BUFFER_SIZE - 1
mApiReturn = CallDLL32("kernel32","GetLocaleInfoA",LOCALE_USER_DEFAULT,LOCALE_SMONDECIMALSEP,&mBuffer,mBufferSize)
mBuffer = Left(mBuffer,mApiReturn - 1)
RESULT mBuffer
Acknowledgement: Originally, this code has been taken from the <a href="[
www.windasso.org];
WinDAsso</b></u></a> web site. However, I cannot find the routine anymore on their site.
Regards,
Guenter