Run application after successful install

2020-05-30 03:28发布

问题:

How to make check box that allow user to run application after installation?

回答1:

Check the postinstall flag in the [Run] section, see the documentation at https://jrsoftware.org/ishelp/topic_runsection.htm#postinstall



回答2:

There you go:


under [Run]:

Filename: {app}\{cm:AppName}.exe; Description: {cm:LaunchProgram,{cm:AppName}}; Flags: nowait postinstall skipifsilent

under [CustomMessages]:

AppName=mySoftwaresNiceName
LaunchProgram=Start mySoftware after finishing installation


回答3:

Add Filename to Run Section with Flag postinstall.

Example for Copy&Paste:

[Run]
// User selected... these files are shown for launch after everything is done
Filename: {app}\README.TXT; Description: View the README file; Flags: postinstall shellexec skipifsilent
Filename: {app}\APP.EXE; Description: Run Application; Flags: postinstall nowait skipifsilent unchecked


回答4:

To make the checkbox, create a task:

[Tasks]
Name: StartAfterInstall; Description: Run application after install

and bind it to "run" action:

[Run]
Filename: {app}\{#exe}; Flags: shellexec skipifsilent nowait; Tasks: StartAfterInstall

where {#exe} is the name of exe-file



标签: inno-setup