Cicode Programming Reference > Cicode Function Categories > Display Functions > DspSym

DspSym

Displays a symbol or a Genie at a specified AN. This dynamically displayed object will disappear at page navigation.

To display a Genie, the Genie should be configured to be used with this function. See "Create a New Genie" topic for more information.

Syntax

DspSym(iAN, sSymbol [, iMode] [, iType] )

iAN:

The AN where the symbol will be displayed.

sSymbol:

The name of the symbol to display in the format <[LibName.]SymName>. If you do not specify the library name, a symbol from the Global library will display (if it exists).

iMode:

Not used. The mode is always set to 1, which means do not erase the existing symbol, just draw the new symbol.

iType:

Symbol Type:

Note:Type 0 symbols do not erase existing objects whilst type 1, 2, 3, 4, 5 symbols erase existing objects at the AN.

Return Value

0 (zero) if successful, otherwise one of the following errors will be returned. A hardware alarm is also raised against DspSym when there is an error message.

Related Functions

DspDel

Example

! Display the centrifuge symbol (from the pumps library) at AN25.
DspSym(25,"Pumps.Centrifuge");
! Display the centrifuge symbol (from the global library) at AN26.
DspSym(26,"Centrifuge");
! Display the dspgenie1 genie from testlib library at an animation number indicated by iAn1. 
DspSym(iAn1, "testlib.dspgenie1", 1, 1)
! Display the genie specified in the record of priority 1 on alarm priority table, specified by Library Name and Genie Name fields, at an animation number indicated by iAn4. 
iResult = DspSym(iAn4, "1", 1, 2);
! Display the genie thumbnail specified in the record of priority 1 on alarm priority table, specified by Library Name and Thumbnail Name fields, at an animation number indicated by iAn9. 
DspSym(iAn9, "3", 1, 3);
! Display the genie specified in the record of "Shelved / Disabled" on Alarm Modes table, specified by Library Name and Genie Name fields, at an animation number indicated by iAn4.
iResult = DspSym(iAn4, "Shelved / Disabled", 1, 4);
! Display the genie specified in the record of "Shelved / Disabled" on Alarm Modes table, specified by Library Name and Thumbnail Name fields, at an animation number indicated by iAn7.
iResult = DspSym(iAn7, "Shelved / Disabled", 1, 5);

See Also

Display Functions

Published June 2018