Jump to content


This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.
Photo

Launch an executable after reboot


3 replies to this topic

jagat

jagat
  • Members
  • 15 posts

Posted 06 July 2002 - 14:49

hi,
I am facing a typical problem.We wanted to launch an application after the installation is completed.But on clicking the Setup complete Success Dialog ,sometimes the setup is asking for reboot.Hence the application is not getting executed if restart the system is clicked.Otherwise it works fine.I am using Developer 7.01 Basic msi project.
Is there any way to counter the above problem ???
Thanks in advance.
Regards,
jagat
Software Engineer
http://www.icode.com

luke_s

luke_s
  • Full Members
  • 532 posts

Posted 08 July 2002 - 01:06

The way to run an executable after a reboot is to use the RunOnce registry key.

HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Runonce

You will need to create a custom action to set this value before you reboot, and then when you reboot the command that you set will be run. It is then removed after it has been run.

jagat

jagat
  • Members
  • 15 posts

Posted 08 July 2002 - 15:52

Hi luke,
Thank you very much for the information. It works brilliantly.
But the problem is how can I get the information that the system requires reboot after the installation is complete. It is handled internally by Window Installer. So if I would write the registry entries then it would be executed once at any cost .
I am using the Custom action with the following properties..
-> Launch an Executable
-> Stored in the Binary Table.
-> Ignore Custom action return code.
Can you please guide me through..
Regards,
Jagat
jagat
Software Engineer
http://www.icode.com

PhilWilson

PhilWilson
  • Members
  • 10 posts

Posted 12 July 2002 - 22:37

The ReplacedInUseFiles property might help - it's set if the installer has replaced files and needs to reboot.