Archive: Install without administrator rights


Install without administrator rights
Hi,

Thanks to NSIS (many many thanks I should say), writing an (un)install script is straightforward when the user has administrator rights, ie when the user is allowed to define new registry keys.

But what if this is not the case ?
-) Should one write a log file to store information for the uninstall process? How does that work ?
-) Is there a more elegant/waterproof way ?
-) Will the install be restricted to the user or can we make it available to all users of the machine ?

I'll appreciate any hints http://forums.winamp.com/images/icons/icon7.gif


You can check for admin using the UserInfo plugin (included with NSIS--see the examples folder for instructions) and then display a message box and abort if the user is not admin.

As for the other questions:

create a log file: I'm not sure it will help with admin/regular user problem, but if you wanted to create an install log, there are several options for this that are documented both in the NSIS help or in this forum. Try searching both.

Installing for all users: Search NSIS help for "SetShellVarContext"