Martin v. Löwis
Martin v. Löwis

Reputation: 127447

Make UAC optional in Windows Installer on Vista

I'm have written an msi file that offers a choice of "per-user" or "for all" installation in the UI phase, and now find that the installer fails on Vista:

So: how can I prevent installer from invoking UAC when it isn't really needed? Alternatively, how can I programmatically request UAC even if bit 3 is set?

Upvotes: 16

Views: 2295

Answers (3)

Rob Mensching
Rob Mensching

Reputation: 35866

Unfortunately, the Windows Installer does not provide a way to create a single package that can install per-machine and per-user but only prompt for UAC on the per-machine case. The issue is that the bit that can suppress the UAC prompt is stored in the SummaryInformation stream and is not modifiable while the package is executing.

Upvotes: 6

user114165
user114165

Reputation:

I turned off UAC by setting the bit 3 of PID_WORDCOUNT in my MSI package. I can able to install it for "ALLUSERS" and "PER-USER", and also write in for HKLM in both the modes on VISTA machines. Is it mandatory for you to get UAC popup for privileged user during installation?

Upvotes: 1

Related Questions