Skip to main content

WizardService Class

Allows you to use the Wizard control in compliance with MVVM.

Namespace: DevExpress.Xpf.Controls

Assembly: DevExpress.Xpf.Controls.v24.1.dll

NuGet Package: DevExpress.Wpf.Controls

Declaration

[TargetType(typeof(Wizard))]
public class WizardService :
    ViewServiceBase,
    IWizardService

Remarks

To learn more, see WizardService.

Example

This example demonstrates how to use the WizardService. See Implementation Details for more information.

See also:

How to create a Wizard with pages defined in XAML

How to: Create a wizard based on a collection of view models

View Example

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using DevExpress.Mvvm;
using DevExpress.Mvvm.POCO;

namespace VM_DrivenWizard.ViewModels {
    public class CongratulationsPageViewModel : WizardViewModelBase, ISupportWizardFinishCommand {
        protected CongratulationsPageViewModel() {
            ShowBack = true;
            ShowCancel = true;
            ShowFinish = true;
            AllowBack = true;
        }
        public bool CanFinish {
            get { return true; }
        }

        public void OnFinish(CancelEventArgs e) {
            this.GetService<IMessageBoxService>().ShowMessage("Thank you for completing this WPF feature tour!", "WPF Tour", MessageButton.OK, MessageIcon.Exclamation);
        }
        protected override bool GetCanCancel() {
            return false;
        }
    }
}

The following code snippet (auto-collected from DevExpress Examples) contains a reference to the WizardService class.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

Inheritance

Show 12 items
Object
DispatcherObject
DependencyObject
Freezable
Animatable
DevExpress.Mvvm.UI.Interactivity.AttachableObjectBase
DevExpress.Mvvm.UI.Interactivity.Behavior
DevExpress.Mvvm.UI.Interactivity.Behavior<FrameworkElement>
DevExpress.Mvvm.UI.ServiceBaseGeneric<FrameworkElement>
See Also