There
is a quick way to launch a program that accesses environment variables
based on configuration information you define prior to running the
program. To run a program that accesses environment variables, complete
the following steps:
- Switch to the z/OS® Projects
perspective.
- Define a launch configuration that includes specific environment
variables or input parameters for the executable.
- On the workbench toolbar, click the Run icon and select Run.
- In the configurations list, click Compiled
Application, then click the New launch configuration icon.
- In the Name field, type a name for the launch configuration. This name will be added to a list of options under a Run
With Configuration menu. Choose a name that you can associate
with the program, input parameters, and environment variable values
defined in the launch configuration.
- On the Main tab, define the Project,
Program name, and Program parameters in the respective fields.
- On the System Environment tab, specify
values for environment variables that the executable will query at
run time.
- On the Common tab, define the type
of launch configuration and the perspective you want to use for each
launch mode.
- Click Apply and Close.
- Run the program
- In the Projects view, find the executable you want to
run.
- Right-click the executable and select Run
With Configuration > (launch configuration name you defined previously).
This approach runs a program with the input parameters or
program-specific environment variables you defined in the launch configuration.