This method executes a command and returns the output as string.
The executable can return information by sending strings to stdout. If the executable returns more than one line, the lines are concatenated to produce one string.
On the OS/400 platform, the supported commands are:
commands that start with the system (when using a CL command)
commands that run on the Qshell (qsh) utility. Use the
-c option when using the
qsh command.
For example:
qsh -c ls
system DSPDTAARA DTAARA (<LibName>/<Data Area Name>)
Type
Synchronous, IMPACT_ACTION_INFO
Arguments
Name
Type
Description
command
String
The command to execute.
External and internal variables can be used in the command string.