joefio
Posts: 23
Joined: Thu Apr 20, 2023 2:14 pm

Call exe with command line arguments

I have a file config.exe that is required to run at the end of the installation in order to configure the installed program. Based on the documentation it seems that the "Launch installed file" custom action should accomplish this. However, the config.exe requires cmd line arguments passed to it. I see that in the properties under "Launch installed file" there is a field "Command Line:", however I'm not sure exactly how this works.

In the NSIS installer I used previously, I would call "config.exe /i [path]". Would I put "config.exe /i [path]" in the command line field? Or would I just put the arguments here "/i [path]"?
launchinstalled.PNG
launchinstalled.PNG (75.95 KiB) Viewed 3550 times
I would appreciate any help here. Thanks
Catalin
Posts: 6586
Joined: Wed Jun 13, 2018 7:49 am

Re: Call exe with command line arguments

Hello and welcome to our forums,

The EXE is basically already given as an argument, so you would need to only pass the "/i [path]" part.

Please make sure you add the custom action after the "Add resources" action group (this is when your files are copied on the disk).

Hope this helps!

Best regards,
Catalin
Catalin Gheorghe - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Building Installers”