I created 2 simple wix msi's and bundled them into a burn installer. Disliking the default UI from burn I found Andrei Mușat's awesome example of a custom UI here: Custom BURN UI
I'd like to run this in silent mode In the UI Bootstrapper, the Run cmd:
protected override void Run()
{
Engine.Log(LogLevel.Verbose, "Entry point of WiX - Run method");
using (var container = SetupCompositionContainer())
{
bootstrapperBundleData = new BootstrapperBundleData();
Engine.Log(LogLevel.Verbose, JsonConvert.SerializeObject(bootstrapperBundleData));
// Create main window with associated view model
installerUIWindow = container.GetExportedValue<Window>("InstallerUIWindow");
installerUIWindowHandle = new WindowInteropHelper(installerUIWindow).EnsureHandle();
Engine.Detect();
if (Command.Display == Display.Passive || Command.Display == Display.Full)
{
installerUIWindow.Show();
}
else{
Engine.Log(LogLevel.Verbose, "Running silent mode");
}
Dispatcher.Run();
Engine.Quit(0);
Engine.Log(LogLevel.Verbose, "Exiting custom WPF UI.");
}
}
In the InstallerUIWIndowViewModel, I see this:
InstallCommandValue = new DelegateCommand(
() => engine.Plan(LaunchAction.Install),
() => !Installing && Status == InstallationStatus.DetectedAbsent);
UninstallCommandValue = new DelegateCommand(
() => engine.Plan(LaunchAction.Uninstall),
() => !Installing && Status == InstallationStatus.DetectedPresent);
CancelCommandValue = new DelegateCommand(
() => IsCancelled = true);
So how do you call the InstallCmd without showing the UI?
Thanks