Add a Custom Pick Action

To add a custom pick action to a custom pick action menu:

  1. Display the Pick Menu window (see Using the Pick Menu Window).
  2. In the pick action menu tree structure, select the custom menu to which you want to add a custom pick action.
  3. Select the Add Action button.
    The Pick Action Configuration window is displayed.

    The Pick Action Configuration window has an extra setting when displayed for custom menu pick actions—the Animate Parameter check box. For more information on this setting, see Associating a Custom Menu Pick Action with a Mimic Parameter.

  4. Use the first page of the Pick Action Configuration window to choose the type of pick action that you want to add. The types are:
    • Object Menu—The custom pick action provides access to the pick action options for an object in the database. If you have selected this option and have not enabled the Animate Parameter check box, proceed to step 5.
    • Hyperlink—The custom pick action acts as a hyperlink to another display. If you have selected this option and have not enabled the Animate Parameter check box, proceed to step 6.
    • Method—The custom pick action instigates a method action when selected. If you have selected this option and have not enabled the Animate Parameter check box, proceed to step 7.
    • Script—The custom pick action executes a script when selected. If you have selected this option and have not enabled the Animate Parameter check box, proceed to step 8.
    • Registry—When selected, the custom pick action writes a value to the registry. If you have selected this option and have not enabled the Animate Parameter check box, proceed to step 9.
    • From Geo SCADA Expert 2019 onwards, the location from which the REGISTRY function retrieves a value varies, depending on the type of client from which the function is triggered (see REGISTRY).

    • ViewX Command—The custom pick action performs the same function as a specific command when selected. If you have selected this option and have not enabled the Animate Parameter check box, proceed to step 10.
    • System Command—The custom pick action instigates a system command when selected. If you have selected this option and have not enabled the Animate Parameter check box, proceed to step 11.

    If you select the Animate Parameter check box, you allow the custom action to be associated with a Mimic parameter instead of a specific database object. If you want to associate a custom action with a Mimic parameter, see Associating a Custom Menu Pick Action with a Mimic Parameter. If you do not intend to associate the custom action with a Mimic parameter, clear the Animate Parameter check box.

  5. Define the settings for the Object pick action menu:
    • Use the browse button feature of the Object field to choose a database item. The database item that you choose is the database item that provides the pick action menu that is associated with the custom pick action.
    • Use the Options section to choose the options that are to be included (select to include; clear to exclude).
    • Use the Relative check box to define whether the custom pick action uses an absolute or relative reference to link to the selected database item. If the check box is selected, the custom pick action uses a relative reference. Proceed to step 12.
  6. Define the settings for the target display:
    • Use the URL field's browse button to select the target display.
    • Use the Mode combo box to define where the target display is shown
    • Use the spin boxes to define the positioning and sizing of the target display (where appropriate).
    • Use the Relative check box to define whether the custom pick action uses an absolute or relative reference to link to the selected display. If the check box is selected, the custom pick action uses a relative reference.

    These settings work in the same way as the corresponding settings on the Pick Action Configuration Wizard for hyperlinks (see Using the Pick Action Wizard to Create a Hyperlink).

    Proceed to step 12.

  7. Define the settings for the method:
    1. Use the Object field's browse button to select the database item that provides the method that you want to be associated with the pick action. For example, if you want the pick action to write an Override value to a point, use the browse button to select the point.
    2. Use the Method combo box to choose the type of method that is performed when the custom pick action is selected.
    3. Use the Relative check box to define whether the custom pick action uses an absolute or relative reference to link to the selected method. If the check box is selected, the custom pick action uses a relative reference.
    4. Select the Next button to display the next page of the Pick Action Wizard.
    5. Double-click on the parameter that you want to define.
      The Expression window is displayed.
    6. Use the Expression window to define the setting for the parameter. For more information, see Using the Expression Editors in the Geo SCADA Expert Guide to Expressions.
    7. Select the OK button to confirm your selection and close the Expression window.
    8. Repeat steps v to vii inclusive for each parameter.

      These settings work in the same way as the corresponding settings on the Pick Action Configuration Wizard for methods (see Creating a Method Pick Action).

    Proceed to step 12.

  8. Use the Script field's browse button feature to select a preconfigured function or enter any valid script in the field. The selected function or defined script will be executed when the custom pick action is selected. For more information, see Associate a Mimic Script with a Script Pick Action in the Geo SCADA Expert Guide to Scripting.

    Proceed to step 12.

  9. Define the settings for the registry pick action:
    • Use the Name field to enter the name of the registry key.
    • Use the Type combo box to choose the type of value that the registry key is to store.
    • Use the Value field to define the value that is written to the registry key.

    These settings work in the same way as the corresponding settings on the Pick Action Configuration Wizard for registry key pick actions (see Creating a Registry Pick Action).

    From Geo SCADA Expert 2019 onwards, the location from which the REGISTRY function retrieves a value varies, depending on the type of client from which the function is triggered (see REGISTRY).

    Proceed to step 12.

  10. Use the Command combo box to select the type of ViewX command that will be performed when the custom pick action is selected. Each command corresponds to an option on the ViewX ribbon or File menu. For more information, see Creating a ViewX Command Pick Action.

    Proceed to step 12.

  11. Define a system command for the custom pick action:
    • Use the Command browse button to select an application to run when the custom pick action is selected. Alternatively, enter a system command in the field.
    • Use the Permission combo box to choose the permission that controls whether a user can use the pick action to perform a system command. Only users that have the selected permission for the host Mimic (the Mimic that provides access to the custom pick action) can select the custom pick action.

    For more information, see Creating a System Command Pick Action.

    Proceed to step 12.

  12. Enter an expression to define the availability of the pick action in the expression field, or leave the field empty to set the pick action to be available. If you choose to enter an expression, the value of the expression has to be convertible to a Boolean value (as the action will be available when the expression is true and unavailable when it is false). If a custom action is unavailable, it does not appear on the custom menu.

    For more information on the syntax for expressions, see Understanding the Basics of Expressions in the Geo SCADA Expert Guide to Expressions.

  13. Select the Next button to confirm.
  14. Select the Finish button to confirm your choices and close the Pick Action Configuration window.
    The custom pick action is added to the custom pick action menu structure.

You can change its position if required—see Change the Order of Custom Pick Actions, Menus, and Separator Lines.


Disclaimer

Geo SCADA Expert 2019