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

AVEVA™ Plant SCADA

DspRtfFileSetName

  • Last UpdatedJul 18, 2023
  • 2 minute read

Sets the name of the rich text / text file that is to be displayed on the page based on the file_rtf template.

Syntax

DspRtfFileSetName(sFile [, iAN [, iMode [, iWidth [, iHeight [, sFontName [, iFontSize [, iFontColor [, iBackColor [, iWordWrap [, iScrollbars]]]]]]]]]])

sFile

The full path file name of the file to be displayed. The file can be in either Rich Text File (RTF) format or plain text format.

iAN

The AN where the CiTextBox ActiveX control is located. Do not specify this argument or set this to -1 to let the template handle the AN. Default value -1.

iMode

The display mode of the CiTextBox control. Default value 1.

1 - Locked (disallow editing)

2 - Allow saved (enables save option in context menu)

4 - Allow create (creates the file if it does not already exist)

8 - Allow open (enable open option in context menu)

You can use the combination of the above modes by adding the modes together.

The following parameters are internally used by the template. They are set to the defaults when the text box is initialized. They are not used on subsequent calls.

iWidth

Number of pixels of the width of the text box, defaults to 100 if not specified or -1.

iHeight

Number of pixels of the height of the text box, defaults to 100 if not specified or -1.

sFontName

Name of font used for plain text file, defaults to Arial if not specified or empty string.

iFontSize

Size of font used for plain text file, defaults to 10 point size if not specified or -1.

iFontColor

RGB value for the color of font (text), defaults to 0 (black) if not specified or -1.

iBackColor

RGB value for the background color of the text box, defaults to -1 (white) if not specified.

iWordWrap

whether to wrap text, applies to text file only, defaults to -1 (true) if not specified.

iScrollbars

Whether to show scroll bars on text box if the contents of the file exceeds the display size, defaults to 3 if not specified.

0 - no scrollbars

1 - horizontal scroll bar only

2 - vertical scroll bar only

You can use the combination of the above modes by adding the modes together.

Return Value

Zero (0) if run successfully, otherwise error code is returned.

DspRtfFileGetAn, DspRtfFileGetName

See Also

Tab Style Template Functions

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