SET.ECS.MAP()

SET.ECS.MAP()

Top  Previous  Next

 

The SET.ECS.MAP() function selects a given ECS character map.

 

 

Format

 

SET.ECS.MAP(name)

 

where

 

nameevaluates to the name of the ECS character map to be loaded. A null string loads the default map.

 

 

The SET.ECS.MAP() function allows a program to change the character map on an ECS mode system.

 

The map name is converted to uppercase internally. Use of a null string as the name loads the default character map as set in the QM configuration parameters.

 

The function returns a Boolean value indicating whether it was successful. Failure to install a new map leaves the previous map in place. Use of this function on a non-ECS system always returns False.

 

A program can determine the name of the currently loaded character map by use of the SYSTEM(1021) function.

 

 
Example

 

OLD.MAP = SYSTEM(1021)

IF NOT(SET.ECS.MAP('UNICODE') THEN

  STOP 'Cannot load Unicode map'

END

 

The above program fragment saves the current character map name and then attempts to load the Unicode map, terminating the program if unsuccessful.

 

 

See also:

Extended Character Set Support, ECS.MAP, SYSTEM()