Our project settings include both installationScope=allusers and requestedExecutionLevel=requireAdministrator. However, we've discovered that the installer does not seem to work properly when UAC is switched off by selecting "Never Notify" from "Control Panel -> User Accounts -> Change User Account Control settings" on Windows 7.

When the installer is run from a regular user account, the elevation box is not displayed (obviously because it's turned off in the system), but the installer proceeds without checking that the current user has administrative privileges. This causes all kinds of strange behavior when the installer hits no permissions error: - Files/directories are not created - Uninstall entry is not created in registry - Etc.

Could you please advise how we should proceed in this case to make sure that the installer exits if the current user does not possess administrative privileges? Can this be done using Bitrock, or we would have to add a pre-install hook with a custom executable?

Thanks a lot Giga

asked 19 Mar '13, 11:28

GigaG's gravatar image

accept rate: 0%

Setting <requireInstallationByRootUser> to 1 will cause the installer to exit if current user is not an administrator.

For example:

<project> <requireInstallationByRootUser>1</requireInstallationByRootUser> <!-- ... --> </project>

Also, the ${installer_is_root_install} variable can be used to check if user is administrator on Windows.


answered 20 Mar '13, 09:21

wojciechka's gravatar image

wojciechka ♦♦
accept rate: 26%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here



Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported



Asked: 19 Mar '13, 11:28

Seen: 1,200 times

Last updated: 20 Mar '13, 09:21