-    HOW TO: Unterstützung nationaler Zeichensätze    

NLS Support in UD6/CMtool

UD6 is designed to work with the National Language Support of your operating system.

One of the many disadvantages of the format that Uniface stores it’s source code in is that character set translation is performed on all Input/Output. This often means that even though national characters, like umlauts or even Hebrew characters are represented correctly when displayed in a Uniface application, they are stored in a cryptic TRX format in the database or the XML files produced by Uniface 7.2.05 export facility.

One of the main areas that this can be seen in is a Uniface message. For instance, when Uniface messages in Hebrew are exported in XML format from Uniface 7.2.05, this is the result:

This makes these XML files useless for the exchange of anything other than US-ASCII.

Using UD6/CMtool National Language Support, you can obtain a more useful result:

UD6/CMtool introduced NLS in version 1.02. Support will be expanded in future releases depending on customer demand. The support in version 1.02 extends to correct stylesheet translation of the encoding, so that non US-ASCII XML can be viewed in IE5:

To use NLS support with UD6/CMtool, some additional settings must be placed in your assignment file, and the nls0 configuration file may need to be modified. This example shows the driver setting for storing Hebrew (these should be in addition to any other settings described elsewhere for USYS$UD6_PARAMS):

USYS$UD6_PARAMS=notrx,mmf binary font 56 encoding ISO-8859-8

This example shows the driver setting for storing European characters (these should be in addition to any other settings described elsewhere for USYS$UD6_PARAMS):

USYS$UD6_PARAMS=notrx,mmf binary font 51 encoding ISO-8859-1

NOTE: You cannot use UD6/CMtool to store the UGLYPH or UCSDIA entities when ‘notrx’ is specified. This may cause unstable behavior in the driver.

NOTE: The mmf binary font nn must agree with the ‘nls0’ file being used. For instance if you use nls1255 the setting should be mmf binary font 56. However if you are using the default nls0, setting mmf binary font 56 will have no effect.

The usys:/bin directory should contain several ‘nls’ files, eg: nls437. Select whichever is the correct one for your environment and rename it to nls0. The default nls0 is for CP1252, other national languages and their code page are shown below:

RegionCode Page
Central EuropeCP1250
CryllicCP1251
ArabicCP1256
GreekCP1253
HebrewCP1255

NOTE: NLS support can slow the driver down noticeably, particularly when writing tables with a LARGE number of NLS strings (e.g.: loading the messages table for the first time). The only way of combating this problem is to alter the joins file, so that each message is stored in its own individual file (please contact March Hare support at support@march-hare.com for assistance with the joins file).

NLS files that come with the driver

Included with UD6 1.02 are the following nls support files:

FileCode PageFont numberLanguage(s)
Nls051CP1255English, German, French, Italian, Spanish, Portuguese, Swedish, Icelandic, Finnish, Dutch, Danish, Faeroese, Norwegian
Nls125556CP1255Hebrew

The NLS file that the UD6/CMtool Driver uses depends on the default code page for the operating system you are using. If the resulting XML files contain too many <ufont …> tags, then you may need to delete nls0 and replace it with a copy of the appropriate nls file (or write your own).

e.g.:


<ufont num="56">êñ</font> <font num="56">à</font>

Alternatively, if you have replaced nls0 and you are getting the same behavior, it could be that code page 0 is NOT the default for your operating system. You can find the default code page in use by starting the driver with USYS$UD6_PARAMS=listoptions and then viewing the message frame.

e.g.:


unicode = 0
unicode noenc = 1
codepage = 1255
locale = C
formtoolkit = 1

For more information on these settings please read the section on USYS$UD6_PARAMS .

Further Information

How the driver works with Source Code Control
Using UD6 for EDI/XML Data Interchange
Format of the files
Unicode Support in UD6/CMtool
Modifying the XML files directly
Differences between UD6/CMtool and UD7/XML-DATA and W3C XML-DATA format
Division of the entities

UD6 Overview
How to use the driver with a configuration management solution

$Revision: 1.9.2.4 $ $Date: 2003/09/16 17:52:05 $[zum Seitenanfang]