O'Reilly logo

Applied WPF 4 in Context by Raffaele Garofalo

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

The View Models

When you create an application in WPF like the TimeTracker application, you will have a project that has some views, and each view will display some data. You can decide to display this data in a lot of different ways; some of them will require more effort than others.

In any case, you will need to present to each view a specific set of values to be displayed and a specific presentation logic that will be applied to the UI. In WPF you provide this information to the view by using an object that takes the name of DataContext. In WPF you can think of the DataContext dependency property of an element as a container of data; more precisely, it is the container for the data bound to that specific element. Because the DataContext property ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required