Publication date : 08/27/2024

Course : .NET, master MVVM to create WPF applications

Practical course - 3d - 21h00 - Ref. NWP
Price : 1650 € E.T.

.NET, master MVVM to create WPF applications




This training course presents the MVVM design pattern and its advantages, particularly testability. In a series of hands-on exercises in C# and Visual Studio, you will gradually transform a simple WPF application into a WPF application based on the MVVM architecture, using the MS MVVM Toolkit.


INTER
IN-HOUSE
CUSTOM

Practical course in person or remote class
Disponible en anglais, à la demande

Ref. NWP
  3d - 21h00
1650 € E.T.




This training course presents the MVVM design pattern and its advantages, particularly testability. In a series of hands-on exercises in C# and Visual Studio, you will gradually transform a simple WPF application into a WPF application based on the MVVM architecture, using the MS MVVM Toolkit.


Teaching objectives
At the end of the training, the participant will be able to:
Understand application architecture rules and concepts
Understanding the benefits of MVVM architecture with WPF
Create and integrate ViewModels into views
Implement unit tests on ViewModels
Installing and mastering MS MVVM Toolkit

Intended audience
.NET developers wishing to understand the benefits of the MVVM pattern.

Prerequisites
Good knowledge of C# with Framework 4 or equivalent to that acquired in the course ".NET, creating WPF applications" (ref. NPF).

Practical details
Hands-on work
Workshops to implement MVVM, starting with a WPF application linked to data without MVVM architecture.
Teaching methods
Alternating between lectures, case studies and practical exercises.

Course schedule

1
WPF application fundamentals

  • Fundamental XAML concepts.
  • DataBinding.
  • Validation techniques with error display.
  • Interest in commands versus routed events.
  • Simplify commands with the RelayCommand class.
Hands-on work
Analyse d'une application WPF typique liée à des données avec validations, sans architecture MVVM.

2
Benefits of MVVM architecture

  • SOLID and SOC design rules.
  • Common design patterns (Design Patterns, Layered Model, MVC, MVP, Repository and Locator).
  • MVVM architecture: breakdown and interactions between the different parts.
Hands-on work
Analysis of the steps involved in transforming a simple WPF application linked to data with code-behind to an MVVM architecture.

3
Refactoring a typical application

  • Analysis of a typical code-behind application (without MVVM), with data links.
  • Organization and creation of ViewModels.
  • Declarative and code-based integration of ViewModels with views.
  • Integration of commands with ViewModels and views, with availability management and parameterization.
Hands-on work
Gradual replacement of the application's view behind code by ViewModels derived from a BaseViewModel class, with integration of the various command types.

4
MVVM tools and patterns

  • Analysis of coupling issues between concrete classes.
  • Principle of DI (Dependency Injection) and Locator patterns.
  • Principle and implementation of unit tests.
  • Mocking for easy testing.
Hands-on work
Creation of a ViewModelLocator class to manage ViewModels and services with dependency injection. Create a unit test project for ViewModels.

5
Implementing MS MVVM Toolkit

  • Comparative overview of the main MVVM tools and frameworks available.
  • MS MVVM Toolkit: features and installation.
  • Principle and implementation of IOC with the dependency injection system.
  • Using the Messenger class to enable ViewModels to communicate.
Hands-on work
Amélioration de l'application avec MS MVVM Toolkit grâce aux outils présentés (ObservableObject, Messenger et IServiceProvider).


Dates and locations
Select your location or opt for the remote class then choose your date.
Remote class

Dernières places
Date garantie en présentiel ou à distance
Session garantie

REMOTE CLASS
2026 : 24 June, 16 Dec.

PARIS LA DÉFENSE
2026 : 24 June, 16 Dec.