using dotNetInstaller 2.1.528
Elevating both Prerequisite and MSI
As detailed in the links below, when using dotNetInstaller bootstrapper: Under the “Runtime” section set the “administrator_required” to “True” this will allow dotNetInstaller to elevate components
So installing .NET 4 prerequisite starts to work when administrator_required is true, even if user does not run the installer with "Run as Administrator".
But now the msi is run with elevated privileges as well! Even though it is built for per user / non-elevated installs and running the msi directly installs it fine without any elevation (built with WiX).
dotNetInstaller: UAC Elevation on Install http://code.dblock.org/dotnetinstaller-uac-elevation-on-install
Configuring dotNetInstaller 2.0 to install custom prerequisites and then run a custom exe with elevated privileges. http://geekswithblogs.net/JaydPage/archive/2011/03/31/configuring-dotnetinstaler-2.0-to-install-custom-prerequisites-and-then-run.aspx
How to Elevate Only Prerequisite but Not MSI?
My .msi is per user not per machine and if the .NET 4 prerequisite is already installed then there is no need for elevation at all.
And the unnecessary elevation of (per-user) msi has the further effect of requiring elevation for uninstall.
How to achieve selectivity - elevate .NET 4 installer, but not the application msi?