Define a Run a Program Action

Use the Run a Program Action to launch any program that can be run from a Windows command line. For example, add a One-Step™ Action to a button, link, menu bar, or task pane of an Incident record so that Technicians can run a program to reset a password, page a technician, or ping a server directly from a record.

To define a Run a Program Action for a One-Step Action:

  1. Open the One-Step Editor.
  2. Add a Run a Program Action to the Designer Board.
  3. Define general properties for the Run a Program Action:
    Option Description
    Name Provide a display name for the Action (this is how the Action is identified within the One-Step Action).
    Filename Provide the name (using text and/or Tokens) of the program or file to launch, or click the Ellipses button to navigate to the program or file on your computer.
    Start In If the program or file should start running in a particular directory, then provide the name of that directory (using text and/or Tokens), or click the Ellipses button to browse to the directory on your computer. If no directory is specified, the current working directory is used (this is usually the directory from which CSM was launched).
  4. Define command-line arguments: Provide any arguments that must be passed to the program (using text and/or Tokens). Tokens are passed to the program as parameters.
  5. Define how the One-Step Action should interact with the program:
    Option Description
    Wait for Program to End before Continuing Select this check box to have the One-Step Action wait until the program finishes executing before continuing to the next Action.
    Timeout after X Seconds When the Wait for Program to End before Continuing check box is selected, specify a timeout period in seconds. The program either waits until the program is finished executing or the specified number of seconds has passed.
    Store Exit Code from Program Select this check box to store the program’s return code for use in future One-Step Actions. A name is provided for the variable that will hold the return code (example: Run program result). The variable is available in the system so you can reuse it. This is not required; however, in most cases, you want to store the program result so that you can do something with it (example: Create a Journal - History record that stores the result).
  6. Define how the program should run:
    Option Description
    Run In the drop-down, select the size of window (normal, minimized, maximized, or no window) to open the program in. This applies to a command prompt window as well as the executable program. The command prompt window is in the background and is not shown to Users.
    Custom Run Verb Uses a custom run verb. This is an additional parameter that tells the program how to run (if the program requires one). Some common verbs are new, open, edit, and print. Consult the program’s documentation to find out what verbs are available. If the program makes its list of supported verbs available, they are available in the drop-down.
    Pause after Run The One-Step Action pauses for a few extra seconds after running the program before continuing to the next Action; the User specifies the number of seconds the One-Step Action should pause.
  7. Define Annotation properties.
  8. Click Save.
© Copyright 2018 Cherwell Software, LLC. All rights reserved.