I've created a WIX Burn Bundle. In the Bundle I install .Net 4 (if its not installed) then 2 more .msi files. 1 is a third part msi the other a msi I created for my software using WIX. I need to be an Administrator on the machine to run these the .msi files.
I want the Burn bundle to not do anything if the user is not an administartor i.e. install nothing. In my product software I can easily do do using below - however I cant do this in the bundle. I've read lots of similar posts but just didnt find a working example for what I want to do.
<CustomAction Id="IsPrivileged" Error="You must be an Administrator to install [ProductName]." />
<InstallExecuteSequence>
<Custom Action='IsPrivileged' Before='LaunchConditions'>
Not Privileged
</Custom>
</InstallExecuteSequence>
You can use the bundle equivalent of launch conditions using Burn's built-in variables and WixBalExtension's Condition element:
<bal:Condition Message="You can't elevate.">
<![CDATA[Privileged <> 0]]>
</bal:Condition>
<bal:Condition Message="You're not elevated.">
WixBundleElevated = 1
</bal:Condition>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With