6 74 LceUsePartition

LANSA Open Guide

6.74 LceUsePartition

Instructs the session to use the specified partition. This function is optional, however, as most of your applications will require a specific partition, this function will generally be used. The default value is "SYS" or the system partition in LANSA.

BOOL

LceUsePartition

(int 

iSession,

 

 

 char far *

strValue )

  

Parameters

iSession

The session identifier as returned by LceGetSessionId.

strValue

The partition name. The length of this parameter should not exceed PARTITION_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. It is similar in concept to a directory on a PC and has a number of characteristics associated with it. The LceUsePartition function is used to specify the partition to be used.

A partition cannot be changed once the session is open. The session must be closed or a new session opened if you wish to use another partition. If you wish to use more than one partition, you must start more than one session. You will need to get another session ID.

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

Related Functions

6.13 LceEndSession

6.46 LceOpenSession

6.73 LceUseLanguage