A wizard-style WPF sample that shows how to navigate between dynamically loaded views using the MVVM pattern and Syncfusion WPF controls. A single window hosts three steps; the Previous and Next buttons swap the content through ViewModel-to-View DataTemplates. It uses no frames, no reflection-based navigation and no third-party MVVM framework.
- MVVM navigation:
MainViewModelexposesNextCommandandPreviousCommand. Previous is disabled on the first step and Next on the last, and the buttons update automatically. - Step 1 – Organization tree:
SfTreeViewwith a four-level hierarchy (departments, teams, employees) and live search. - Step 2 – Editable data grid:
SfDataGridwith 50 sample rows, in-place editing, sorting, filtering and grouping. - Step 3 – Validated form:
SfTextInputLayout,SfTextBoxExt,ComboBoxAdv,DateTimeEditandCheckListBox, with inline validation messages. - Fluent theme:
SfSkinManagerwith the FluentLight theme, plus shared styles inApp.xaml. - No business logic in code-behind. Public members have XML documentation.
- Windows 10 or later
- .NET 8 SDK
- Visual Studio 2022 with the .NET desktop development workload (optional; the CLI also works)
- A Syncfusion license key
git clone https://github.com/SyncfusionExamples/Syncfusion-WPF-Dynamic-Navigation-Workflow.git
cd Syncfusion-WPF-Dynamic-Navigation-Workflow
dotnet run --project WizardAppOr open SyncfusionWizard.sln in Visual Studio and press F5. NuGet packages restore automatically.
In WizardApp/App.xaml.cs, uncomment the line below and add your own key. Do not commit real keys to a public repository.
Syncfusion.Licensing.SyncfusionLicenseProvider.RegisterLicense("YOUR_LICENSE_KEY");- Search and browse the organization in step 1, then click Next.
- Click a cell in the grid to edit it. Use the column headers to sort or filter, and drag a header to the group area to group. Click Next.
- Fill in the form in step 3. Required fields show validation messages until they are valid. Use Previous to go back at any time.
WizardApp/
Commands/ RelayCommand (ICommand implementation)
Converters/ BindingProxy, StringToBoolConverter
Models/ Tree, grid and form data models
Services/ NavigationService, SampleData
ViewModels/ MainViewModel + one ViewModel per step
Views/ MainWindow, ControlA, ControlB, ControlC
All Syncfusion packages are version 35.1.41: Syncfusion.SfGrid.WPF, Syncfusion.SfTreeView.WPF, Syncfusion.SfInput.WPF, Syncfusion.SfTextInputLayout.WPF, Syncfusion.Shared.WPF, Syncfusion.Tools.WPF, Syncfusion.SfSkinManager.WPF and Syncfusion.Themes.FluentLight.WPF.
Syncfusion controls require a valid Syncfusion license (commercial or Community). See the Syncfusion license terms.