Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Scripting_function


Panel
titleDescription

Displays a message to the user in a warning style popup dialog.

Client permissions restrictions


Panel
titleSyntax

system.gui.warningBox(message, [title])

  • Parameters

String message - The message to display in the warning box. Will accept HTML formatting if the message parameter is encapsulated in an <html> tag.

String title - The title for the warning box. [optional]

  • Returns

Nothing

  • Scope

Vision Client

Panel
titleCode Examples
Code Block
languagepy
titleCode Snippet
# This code shows a yellow popup box similar to the system.gui.messageBox function.
# Start the motor, or, warn the user if in wrong mode.
runMode = event.source.parent.getPropertyValue('RunMode')

# Cannot start the motor in mode #1
if runMode == 1: 
   system.gui.warningBox("Cannot start the motor, current mode is <B>VIEW MODE</B>")
else:
   system.db.runUpdateQuery("UPDATE MotorControl SET MotorRun=1")
Panel
titleKeywords

system gui warningBox, gui.warningBox