We have a custom MSI installer that we use to install an older internally developed application. The application was originally deployed to around 100 workstations with no issues as a build time install.

Now every time we attempt to upgrade the application randomly on around 10%-15% of installations the system is setting the appcompat flag so that the exe must run in admin mode for the user.

I've found some info here - https://msdn.microsoft.com/en-us/library/windows/desktop/hh994464(v=vs.85).aspx

But is there anyway of telling exactly what is causing this? Logfiles? I can't see anything in the msi log that is generated on the machines at install. Also our testing didn't show this behaviour which was done while logged in user running the upgrade via SCCM. Nothing I can see in the syslogs or applogs either.



2 Comments   [ + ] Show Comments


  • so everytime you upgrade the application (and MSI) 10 -15 % of target devices set the app compat flag.
    Can you send details of the compat setting, is it the same on ALL devices
  • This content is currently hidden from public view.
    Reason: Removed by member request
    For more information, visit our FAQ's.
  • Sorry, it's set as "Windows Vista" compat mode...and "run this program as Administrator" and no it appears completely random as in out of 100 machines only 15 or so had the prolem
Please log in to comment

Community Chosen Answer

Ahhh the curse of the Windows system trying to help you. Normally this happens when the app is trying to do some dodgey stuff, like write to protected areas. Or Windows analyzes the app and thinks you need elevated access, thinking this is your issue.

I'm talking about the application, not the msi installer. I think this is a application compatibility issue.

Have a look at this for a better understanding:

So how do you fix this? Well first thing to try is set the AppCompat flags, the friendly name for this is called Compatibility Mode - where you right click the exe and set it to WinXP compatibility etc. Apply the setting and test it, test it as a standard user, if it works with no UAC prompt then happy days. What you do next is apply AppCompat settings to the package via the registry, have a look at the link below.

The other option is using manifest files, since the app is compiled in house. Need to watch out here, as you need to check if the app has a manifest already, they can embed them in the exe, or have them outside of the exe in the same folder. Check out this link which will guide you in that direction.

I've never used manifest files, always wanted to give them a try but never had the time as it required a bit of learning (and I never had the time).

Just to note, sometimes the manifest file, if there is one, will ask to run with highest privileges. This means if you have access to the administrator security token it will prompt for UAC, if you're a standard user, then it won't prompt for UAC (unless the app explicitly tries to write to a protected area). Programmers set the manifest to ask for highest permissions for no good reason, were run as in invoker will do the job.
Answered 11/26/2015 by: rileyz
Red Belt

Please log in to comment


It is set in order to make the executable compatible with the current OS.In your case it requires admin rights for proper functionality.When upgraded through SCCM, this was not seen because installations happens in system context when deployed through SCCM.
Answered 11/26/2015 by: apptopack
Red Belt

Please log in to comment
Answer this question or Comment on this question for clarity