Jon Tackabury
Jon Tackabury

Reputation: 49289

Prevent a [Run] entry being processed with Inno Setup installer command line

I am running an installer that I built with Inno Setup, and I want to be able to control whether the applications runs or not after installation. I am using the [RUN] section to control this, but according the Inno docs, command line parameters can only control the [TASKS] section. Is there a way to enable/disable items in the [RUN] section from the command line?

Upvotes: 1

Views: 1285

Answers (1)

Deanna
Deanna

Reputation: 24283

Inno doesn't have an option to do this built in, but you can read the command line parameters and make use of the results in a Check: function on the [Run] entry.
In code, you can use the GetCmdTail, ParamCount and ParamStrfunctions, or the {param:} constant (but it isn't as good for a boolean option)

Upvotes: 2

Related Questions