WPF Series -9- CustomListBox

When we used ListBox controls in our WPF project we faced the same problem as described in the previous post. Like DataGrid, ListBox control also has a property called SelectedItems, which isn’t a dependency property and therefore not bindable too. This post shows how ListBox control can be extended with a bindable version of the […]

WPF Series -8- CustomDataGrid

According to MVVM pattern the ViewModel interacts with the Model but doesn’t know anything about its View. As a result dependency properties of controls get bound to ViewModel properties by specifying bindings in the corresponding View (XAML). DataGrid control has a property called SelectedItems, which in multi selection mode holds the items that are selected. […]

WPF Series -7- ViewModel Validation using DataAnnotations

As we often use Data Annotations for basic validation purposes in context of C#/.NET applications (i.e. required, max length, …), we searched for a solution that allows using Data Annotations in WPF ViewModels for client side validation. Fortunately we found such a solution, which I would like to describe in this blog post. Implement IDataErrorInfo […]