Hello,
I'm rewriting a TP on a cell (KSS5.6, KRC2). At the moment messages are managed through a WOP package which has a dedicated message database called MessAppli.db in C:/DATA.
However, I would prefer to manage the messages independently from the WOP and hard code my messages in a dedicated .dat file, in some kind of CHAR array. Or alternatively to have my own database.
My first question is :
Has my system is in french I need do display my messages in french. But .dat files are automatically transcoded to us-ascii when they are copied to /KRC/R1. Thus, I can't display properly my messages with special or accentuated characters from a CHAR[] variables such as :
Apparently KRL can understand hexa coding inside a char array with the syntax :
So is there a way to know the correspondance between special/accentuated characters and the corresponding hexa code (for instance : "à" => 'HXXX') ?
My seconde question is :
As I said previously, The actual way of doing this is through a message database, in my case named C:/DATA/MessAppli.mdb. This database has mainly two tables, the first is ITEM {keystring, keyid} and the second is MESSAGES {keyid, langid, message}. Thus, for a certain keystring i can display a message in a given language.
When I call Set_KrlMsg (#NOTIFY, msg, msgParams[], msgOptions), if msg.MSG_TXT[] corresponds to a keystring that is actually present in MessAppli.mdb I will display the corresponding message string from the DB. Otherwise, I will simply display the content of MSG_TXT[]. Internally, Set_KrlMsg takes care of the encoding problem I am facing.
So my question is what is the process to create my own independant DB and how can I tell the system to search in this database when calling Set_KrlMsg ? Is this just a matter of adding a regex key somewhere ? Is it more complicated ?