Jump to content

Restart required after LabVIEW installer called from Inno Installer


Recommended Posts

Hey all,

(Cross-post from ni.com forums)

We have a LabVIEW application, which has a LabVIEW-based Installer.  This LabVIEW installer is called from within another Inno installer (since our main Inno installer pulls together multiple components, most of them not LabVIEW).  Whenever this Inno installer ends, it always asks the user to restart their PC, even if the LabVIEW installer was cancelled.

I narrowed it down, and it's reproducible with only the LabVIEW installer, so it's definitely LabVIEW installer's fault.  According to Inno's help documentation, "if a program executed in the [Run] section queues files to be replaced on the next reboot (by calling MoveFileEx or by modifying wininit.ini), Setup will detect this and prompt the user to restart the computer at the end of installation."  However, as stated above, this dialog is triggered even if the LabVIEW installer was cancelled and wrote no files.

Now, the above linked documentation refers to a flag I can put in my installer script to ignore this restart dialog, but it's a global flag, and I would like my other installers to still make use of this handy restart dialog if necessary. Unfortunately it seems LabVIEW installers trigger this even if not actually necessary.

Has anyone seen this before? Any ideas how to make my LabVIEW installer NOT muck around with the MoveFileEx or wininit.ini stuff if/when it's not actually needed?  Attached is a LabVIEW project and Inno Installer script which easily reproduces the problem.  To reproduce:

  1. Extract the attached .zip
  2. Open test.iss in Inno Setup and click the "Run" button
    1. Alternately, just run the built installer under "\Output\test_inno_installer_9.99.0.0.exe"
  3. Click Next on 'Select Components' dialog
  4. Click Install on 'Ready to Install' dialog
  5. When LabVIEW installer pops up click Cancel, then yes (you're sure)
  6. See the Restart dialog

Thanks!

David_L

InnoLabVIEWBug.zip

Edited by David_L
Link to comment

Maybe it would be an option for you to run the installer in silent mode (and/or) with the reboot suppression: Customize and Automate Installation of a Single NI Installer This article might be of some use also: Running a Batch File Automatically After an Installation to Access Installed Files And here's the similar thread, that points to these two articles mentioned.

I also think, there's an option to not use a single LabVIEW installer, but use a bunch of msi installers by pulling them from that .exe and putting all the files into one final Inno setup .exe. You could try to run each msi with one of those flags to suppress the reboot message:

msiexec /qn /i Application.msi REBOOT=ReallySuppress
msiexec /qn /i Application.msi REBOOT=R
msiexec /package Application.msi /norestart
Edited by dadreamer
Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.