17.11 Regional Settings

After installation, each ...\X_LANSA\X_ppp\SOURCE directory should contain a file called x_defppp.h (where ppp is the name of the partition). For example, if the partition is SYS, then the file will be called x_defsys.h.

The x_defppp.h file defines execution settings for your functions that are unique to the partition. (It is similar in concept to the DC@A01 data area on the IBM i). These settings are globally defined to all PROCESSES (and subsequently the functions) in a specific partition.

For example, your decimal point character may be ',' rather than '.' Using this file, you can specify the character that you require once, for all processes and functions in the partition.

The file is formatted as a C header file. It is very easy to understand and to change with any source/text editor, if necessary. You will find the relevant options and values documented within the file.

Any changes made to the values contained in the X_DEFPPP.H file, will require (re)compilation of ALL ENTRY POINT PROCESSES before the changes take effect. Once ALL entry point processes have been (re)compiled you will need to exit and re-enter your LANSA application for the new values to be picked up at execution time.

You should also note that the following values can be set from the LANSA X_RUN command or as a system environment variable:




The order of precedence for the setting of these values is:

A.  Values specified in XENV= parameters on the X_RUN command.

B.  Values specified in normal system environment variables.

C.  Multi-national Values specified in the Development Environment

D.  Country-specific information read from the Windows settings. These values are always available, so in order that the values in x_defxxx.h can still be used, the use of these values can be switched off. To do this define the registry value "OSRegionalSettings" in HKEY_LOCAL_MACHINE\Software\LANSA\X_LANSA registry key as a DWORD and set its value to 0.

E.  Values specified in this file.

     For example, say that you needed to set the X_CENTURY_LESS_DATE value to "20". You can do this using three different methods. These methods can be used independently or together:

There is a fourth method of obtaining the multinational values:
These values are obtained from the LANSAPC registry entry. This is primarily used for LANSA objects that are used to extend the Development Environment such as the Deployment Tool.

Note: If running in LANSA SuperServer, ensure that the Server setting matches the Client setting for X_DECIMAL_POINT_CHAR to avoid values exchanged from a function called via the Built-In Function CALL_SERVER_FUNCTION losing their decimal places.