Runs an external program.
The path to the program to run.
Optional working directory for the program.
Optional flag to control how the program window is shown. See ShowWindowFlag for details.
ShowWindowFlag
The PID of the process if successful, or 0 if failed.
import { Run } from '@ahmic/autoit-js';const pid = Run('notepad.exe');console.log(pid); // Output: 1234 Copy
import { Run } from '@ahmic/autoit-js';const pid = Run('notepad.exe');console.log(pid); // Output: 1234
https://www.autoitscript.com/autoit3/docs/functions/Run.htm
Runs an external program.