Search code examples
windows-installervisual-studio-setup-proje

How to set the custom Microsoft visual studio projects MSI to open it without admin power


I want to know if there some options to set the MSI file without admin power. When I open the msi file in non-admin user, it always need admin power. How can I set it to open the msi file without the admin power?

Based on my search, I find the remote desktop has the behavior, but I could not find the settings in Microsoft Visual Studio Installer Projects.

I want to use MSI installer for non-admin user.


Solution

  • According to my latest test, you only need to set the AlwaysInstallElevated value under the following two registry keys to "1" as the current user, and you can perform MSI installation without administrator privileges.

    HKEY_CURRENT_USER\Software\Policies\Microsoft\Windows\Installer

    HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows\Installer

    You can read this document: https://learn.microsoft.com/en-us/windows/win32/msi/alwaysinstallelevated