O'Reilly logo

WiX 3.6: A Developer's Guide to Windows Installer XML by Nick Ramirez

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Implementing the viewmodel

Now let's move on to viewmodel. Add a new C# class file to the ViewModels folder and name it InstallViewModel. Add the following code:

using CustomBA.Models; using Microsoft.Practices.Prism.Commands; using Microsoft.Practices.Prism.ViewModel; using Microsoft.Tools.WindowsInstallerXml.Bootstrapper; using System; using System.Windows.Input; namespace CustomBA.ViewModels { public class InstallViewModel : NotificationObject { public enum InstallState { Initializing, Present, NotPresent, Applying, Cancelled } private InstallState state; private string message; private BootstrapperApplicationModel model; public ICommand InstallCommand { get; private set; } public ICommand UninstallCommand { get; private set; } public ICommand ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required