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

InTouch HMI

Configuring ActiveX Event Scripts

  • Last UpdatedApr 08, 2022
  • 2 minute read

Use ActiveX event scripts to run a script when an ActiveX event occurs. Depending on the ActiveX control, such events can include:

  • ActiveX control is started: Startup

  • ActiveX control is closed: Shutdown

  • User clicks on ActiveX control: Click

  • User double-clicks on ActiveX control: Doubleclick

An ActiveX event script is identified by a name. By default, the InTouch HMI automatically adds the control name and event that the script is associated with. For example: MyActiveXScript (AlarmViewerCtrl1::Click).

To configure a new ActiveX event script

  1. Double-click on the ActiveX control to configure. The ActiveX control properties dialog box appears.

    Control Name tab in ActiveX control properties dialog

  2. Click the Events tab.

    Events tab in ActiveX control properties dialog

  3. Select an event such as click, double-click, shut down, or start up.

  4. Click in the Scripts cell for that event. Square brackets appear.

  5. Type in a new name for an event script and click OK. When a message appears, click OK to create a new script.

    The ActiveX Event Scripts dialog box appears.

    ActiveX Event Scripts dialog

  6. In the Name box, you can make changes to the ActiveX event script name.

  7. Type your script in the window.

  8. Click OK.

To edit an existing ActiveX event script

  1. In the Scripts pane, expand ActiveX Event, right-click the ActiveX script name and click Edit. The ActiveX Event Scripts dialog box appears.

  2. Make any necessary changes to the script and click OK.

    To delete an existing ActiveX event script

    1. Make sure that no ActiveX controls are using the ActiveX event script to delete. If there are ActiveX controls using the script, do the following first:

      1. Remove the ActiveX event script references in the Events panel of every ActiveX control that may be using it.

      2. Close all windows and update the use counts.

    2. In the Scripts pane, expand ActiveX Event, right-click the ActiveX script name and click Delete. When a message appears, click Yes. The ActiveX event script is deleted.

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