OS2 World Community Forum

OS/2, eCS & ArcaOS - Technical => Programming => Topic started by: Alfredo Fernández Díaz on March 30, 2023, 04:38:13 am

Title: Where / how to read localized equivalents of y/n as used in the system?
Post by: Alfredo Fernández Díaz on March 30, 2023, 04:38:13 am
Hello,

I seem to recall there is a message file where you can read the localized equivalents of "y" and "n" (for example that would be "j" and "n" --ja/nein-- for German) used in NLV OS/2 systems for stuff like simple confirmations, and such.

Any hints/help/reminders?

Thank you in advance,
Title: Re: Where / how to read localized equivalents of y/n as used in the system?
Post by: Martin Iturbide on March 30, 2023, 07:52:46 pm
Hi Alfredo.

Sorry to don't have and answer and ask more.
Do you need to remember the full file name of the ".MSG" file that can help you with that ?

Regards
Title: Re: Where / how to read localized equivalents of y/n as used in the system?
Post by: Dave Yeo on March 31, 2023, 12:01:18 am
Perhaps \os2\system\somd.msg?
Title: Re: Where / how to read localized equivalents of y/n as used in the system?
Post by: Alfredo Fernández Díaz on March 31, 2023, 12:23:39 am
Hi guys, and thank you.
After digging around a bit more, the file is OSO001.msg, and the keys seem to be in the very first message, aka #0. These can be retrieved f.e. with some very simple REXX:
Code: [Select]
/* Get localized equivalents of single confirmation keys and such */
if RxFuncQuery('SysLoadFuncs') then do
  call RxFuncAdd 'SysLoadFuncs','RexxUtil','SysLoadFuncs'
  call SysLoadFuncs
 end
keys = SysGetMessage(0,'OSO001.MSG')
say keys
exit
and naturally you get "Y N A R I" for English, or "S N C R I" for Spanish, and so on.

I got a little worried when I found out the script above yields "Y N A R I" again for Japanese, or "1 2 1 2 3" for Russian, but apparently that is indeed how those work. Trying to format floppies from the command line, which involves this kind of simple confirmation, matches the values contained in the message on a Russian or Japanese system, see screenshots below: