DialogOpen Function

Help Contents

Introduction

Opens the currently defined dialog.

Syntax

Informal Syntax:

DialogOpen( Title, Buttons )

Formal Syntax:

DialogOpen( Title:=Expression, Buttons:=Expression )

Parameters

ParameterTypeDescription
Title ANY_STRING The title that appears at the top of the dialog.
Buttons INT The buttons that appear at the bottom of the dialog:
  1. OK
  2. OK and Cancel
  3. Abort, Retry and Ignore
  4. Yes, No and Cancel
  5. Yes and No
  6. Retry and Cancel

Return Value

An integer value indicating which button closed the dialog:

ValueButton
0Cancel
1OK
2Abort
3Retry
4Ignore
5Yes
6No

Remarks

Any currently running script is suspended while the dialog is open.

After the DialogOpen function completes, the currently defined dialog is reset back to empty.

Examples

In the following example, the dialog defined by the current dialog definition is opened. The dialog has the title "Confirm Action" and both OK and Cancel buttons:

Result := DialogOpen( "Confirm Action", 1 );
IF Result = 1 THEN
    (* OK button Pressed *)
END_IF

Further Information

Operator Actions

To learn where you can use this function.

Glossary

For the meaning of terms used in Fernhill SCADA.