Archive: Reboot and unsaved documents


Reboot and unsaved documents

MessageBoxMB_YESNO|MB_ICONQUESTION|MB_DEFBUTTON1"Restart?"IDNOlbl_noboot

Reboot
lbl_noboot
:
On "Yes" computer is rebooted, but do not offer to save unsaved documents.
Also if I had some open folders before reboot it doesn't open them after reboot.

Somebody knows how to handle these 2 things?

in nsis the reboot command forces all applications to shutdown, his won't let you the opportunity to save your work.

If you want to restart the computer and wait for the user to save documents you should take a look at Autoit.

With Autoit you can create a script that reboots the computer and convert it into an .exe file.

Autoit Homepage

This .exe can be put into the installer, extracted and than called using the Exec command

And for the folders - maybe the explorer settings say that the explorer position isn't saved. In this case explorer windows won't be restored after reboot.


Force reboot flag removed in latest CVS version (EXE needs to be reocompiled, only source uploaded).


I'm using NSISv2.02b2. Is it the latest one?

I did 'SetRebootFlag true' and it gave me reboot option in MUI Finish page. Now if I chose 'reboot' the problem remains: installer closes all unsaved documents without any notification and after rebooting doesn't return all earlier opened folders.


the latest version is always the cvs snapshot which is packed each night.

You can download it here.

Take a look at the NSIS Developer Page. There you can find many resources about NSIS including the NSIS Archive.


You can also use NSIS Update (through the new NSIS menu or directly from Bin\NSIS Update.exe) to download the latest "untested" files from CVS.