Create a WiX MSI which always runs as an administrator

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

Create a WiX MSI which always runs as an administrator

Kaveesh Dashora
This post has NOT been accepted by the mailing list yet.
I am working on creating an installer which has separate features. Each of the features are required to be installed / changed / repaired with admin priviliges.

When I install from the MSI for the first time. The selected features get installed correctly. However, if I run the MSI for the second time under maintanance mode, and perform a change in the features, the change operation is not performed correctly.

If I execute the MSI from an elevated command prompt, the change operation works fine.

Is there a way through which I can force the MSI to request admin privileges, regardless of the mode install / maintanance?

Note - I have tried using


This works fine for install / remove. I get to see the UAC dialog. However performing change / repair does not request for UAC.

This link specifies that the default behaviour of Change / Repair is to run without admin privileges.

So, is it possible to run the MSI elevated directly when it starts?