-
Book Overview & Buying
-
Table Of Contents
-
Feedback & Rating

MVVM Survival Guide for Enterprise Architectures in Silverlight and WPF

We can save ourselves a little effort by taking advantage of one of the many MVVM frameworks freely available on the Web.
See Appendix A, MVVM Frameworks for a list of frameworks.
We are now going to update our code to use the MVVM Light framework by following the steps mentioned next:
If you haven't downloaded the MVVM Light framework then download the framework. See Chapter 2, Introduction to MVVM for details. Also note that there is now an MVVM Light Nuget package (http://nuget.org/packages/mvvmLight) available, which would be the preferred way to install the framework..
Copy GalaSoft.MvvmLight.WPF4.dll
to the Lib
directory in the solution, as shown in the following screenshot. This assembly contains the RelayCommand
class that we will be using.
Add browse reference from Northwind.ViewModel
to GalaSoft.MvvmLight.WPF4.dll
.
Delete the Command.cs
file from Northwind.Application
.
Open MainWindowViewModel.cs
, add a using statement for GalaSoft.MvvmLight.Command...
Change the font size
Change margin width
Change background colour