Method run.itSafe
Overload
Calls run.it and handles exceptions.
If it throws exception, writes it to the output as warning and returns null
.
public static RResult itSafe(string file, string args = null, RFlags flags = 0, ROptions dirEtc = null)
Parameters
file (string)
Examples:
|
args (string)
Command line arguments.
This function expands environment variables if starts with |
flags (RFlags) |
dirEtc (ROptions)
Allows to specify more parameters: current directory, verb, etc.
If string, it sets initial current directory for the new process. If |
Returns
Remarks
This function is useful when you don't care whether it succeeded and don't want to use try/catch. Handles only exception of type AuException. It is thrown when fails, usually when the file does not exist.