OpenUtilities Substation Help

Action Strings

The actions that the product performs when you select a tool, select a menu item, or press a function key are defined by the action string associated with that object. At first it is simplest to think of an action string as a key-in or series of key-ins. For example, the action string associated with the Place SmartLine tool is the key-in PLACE SMARTLINE. The true effect of selecting the Place SmartLine tool is activation of the PLACE SMARTLINE key-in.

Action Types

Several types of actions can be specified in action strings and associated with tools, view controls, menu items, and function keys.

Action type Syntax Description
Command Entry Key-in E,<key-in> Simulates a key-in. The key-in specified by a command entry key-in is always activated, regardless of state of the active key-in. For example, suppose that PLACE CIRCLE RADIUS is the active key-in and is prompting for the radius. If you press a function key defined in the function key menu to have action type E that activates the PLACE LINE CONSTRAINED key-in, then PLACE LINE CONSTRAINED becomes the active key-in.
Terminated Key-in T,<key-in> Simulates a key-in. A terminated key-in is normally used to get data requested by prompts, such as the radius of a circle, text, or an answer to a yes-or-no question.
Unterminated Key-in K,<key-in> Keys in an unterminated string of characters and waits for you to finish the string.
Print Message M,<message> Prints a message in one of the status bar fields.
Note: If no type specifier (a single character separated from the rest of the string with a comma) exists, the product assumes that the action type is a command entry key-in (E).
Note: For examples of action strings, examine the sample tablet menu DGN file provided on the Bentley Communities.

Action Type Options

These options can be used immediately following the E, T, or K action types or anywhere in a multiple action string following a semicolon.

/<character> If there is a slash (/) in an action string, the product pauses for user input. If the slash is followed by d, k, or no character, the product does the following:
  • /d — waits for a data point.
  • /k — waits for a key-in.
  • No character — proceeds after any input.
%<character> A percent (%) character in an action string is identical to the slash, except that the product does not display any of its normal prompts. This is useful to display custom prompts from a menu. The actions %d and %k work analogously to /d and /k.

Entering Multiple Action Strings

Each action string can contain several actions (separated by semicolons).

For example, this action string places a blue two-inch circle at a user-specified point: co=blue;E,PLACE CIRCLE RADIUS;T,2;M,cfPlace 2 Inch Circle;%d;null

The actions are as follows:

Action Description
co=blue A command entry key-in (since no type is specified) that sets the Active Color to blue. The product activates the ACTIVE COLOR key-in even if it currently expects a data key-in.
T,2 A terminated key-in that enters a radius of 2.
M,cfPlace 2 Inch Circle Displays the message "Place 2 Inch Circle" in the status bar.
%d Waits for a data point without displaying the normal prompts (preserving the prompt displayed by the previous action).
null After the circle is placed, executes the NULL key-in so that no tool or view control is selected.