Please ensure Javascript is enabled for purposes of website accessibility
Powered by Zoomin Software. For more details please contactZoomin

AVEVA™ Plant SCADA

DspText

  • Last UpdatedJul 18, 2023
  • 1 minute read

Displays text at a specified AN location. This function does the same operation as DspStr(), however it uses a font number rather than a font name.

Note: This function was designed to only be used on Cicode objects, or the animation point object from the version 3.xx/4.xx toolbox.

Syntax

DspText(hAN, iFont, sText [, iLength] [, iAlignMode] [, iLengthMode] [, bTooltip])

hAN:

The AN where the text will be displayed.

iFont:

The font number that is used to display the text. (To use the default font, set to -1.)

sText:

The text to display.

iLength:

Length of the Text to display, either in characters or pixels depending on Mode (default -1, no truncation).

iAlignMode:

The alignment of the text string:

0 - Left Justified (default).

1 - Right Justified.

2 - Center Justified.

iLengthMode:

The length mode of the text string:

0 - Length as pixels truncated (default).

1 - Length as pixels truncated with ellipsis.

2 - Length interpreted as characters.

bTooltip:

Determines if the original text is provided as tool tip when the displayed text becomes truncated.

0 - Tool tip is not available (default).

1 - Tool tip is available.

Return Value

0 (zero) if successful, otherwise an error is returned.

DspStr, DspFont, DspFontHnd

Example


/* Displays "Display this text" at AN25 using the font defined as
BigFont. */
hBigFont=DspFontHnd("BigFont");
DspText(25,hBigFont,"Display this text");

See Also

Display Functions

In This Topic
Related Links
TitleResults for “How to create a CRG?”Also Available in