I have an exe file that I've created using pyinstaller. I am using Inno Setup to create a Windows installer for this executable.
Here's a snippet from my compiler script :
Filename: "schtasks"; \
Parameters: "/Create /F /SC MINUTE /MO 2 /TN ""Discovery"" /TR ""'{app}\Discovery.exe'"""; \
Flags: runhidden runminimized
I'm using schtasks
to schedule the execution of my exe file (Discovery.exe
). The scheduling works perfectly fine but a command line window still appears when the file runs. This leads me to believe that there's something weird happening with runminimized
and runhidden
Discovery.exe
is in fact a command line application created using pyinstaller.
How do I ensure that no command line window shows up when this file is supposed to run?
Final working [Run] statement on Inno Setup based on the answer by @Bill_Stewart:
[Run]
Filename: "schtasks"; \
Parameters: "/Create /F /SC MINUTE /MO 5 /TN ""Discovery"" /TR ""'wscript.exe' '{app}\RunHidden.js' '{app}\Discovery.exe' "" "; \
Flags: runhidden runminimized;
Note the usage of quotations due to spaces in my file paths.