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 ...

Get WiX 3.6: A Developer's Guide to Windows Installer XML now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.