Contents
Strategic Partner Links
Sepasoft - MES Modules
Cirrus Link - MQTT Modules
Resources
Knowledge Base Articles
Inductive University
Forum
IA Support
SDK Documentation
SDK Examples
Displays a confirmation dialog box to the user with "Yes" and "No" options, and a custom message.
This scripting function has no Client Permission restrictions.
system.gui.confirm(message [, title] [, allowCancel])
String message - The message to show in the confirmation dialog.
String title - The title for the confirmation dialog. [optional]
Boolean allowCancel - Show a cancel button in the dialog. [optional]
Boolean - True (1) if the user selected "Yes", false (0) if the user selected "No", None if the user selected "Cancel".
All
# By using the confirm function in an if statement, we can let the user confirm an action. In this case, we shut down the plant if the user confirms it, otherwise, we don't do anything. if system.gui.confirm("Are you sure you want to shutdown the plant?", "Really Shutdown?"): system.db.runUpdateQuery("UPDATE ControlTable SET Shutdown=1")