6 73 LceUseLanguage

LANSA Open Guide

6.73 LceUseLanguage

Instructs the session to use the specified language. This function is not used in a single language environment.

BOOL

LceUseLanguage

(int

iSession,

 

 

 char far *

strValue )

  

Parameters

iSession

The session identifier as returned by LceGetSessionId.

strValue

The language code as specified in the partition definition. If left blank, the partition default language (i.e. the national language) is assumed. strValue's length should not exceed LANGUAGE_LENGTH as defined in the LCOE.H header file.

  

Return Values

TRUE is returned if the session can accept the value.

FALSE is returned if an error occurs.

Notes

LANSA uses partitions to separate different environments or application work areas. If a partition is defined as multilingual, you will use this function to specify the language to be used in that partition for this session. (For more information regarding multilingual processing, refer to the Partition Multilingual Attributes in the LANSA for iSeries User Guide.) Once a language is specified, details such as field descriptions, labels, etc. will appear in the language specified. File data is not affected.

Multilingual installations:

The actual language details must be recorded in the LANSA Repository on the host. If such details have not been entered for the fields or files being accessed, the equivalent details may instead be returned in the default language.

Single (national) language installations:

If the partition is single language and you execute this function, but do not leave the language code blank, unpredictable results will occur during the call to LceOpenSession.

  • This function must be executed after LceGetSessionId and before LceOpenSession.
  • This function performs no communications to the host.

Related Functions

6.74 LceUsePartition