Contents tagged with Silverlight

  • My frustrations with MVVM in Silverlight

    There is no doubt that the MVVM pattern offers a clean separation of concern for building testable user interfaces with WPF and Silverlight.  This pattern relies on the data binding support in those two technologies for mapping an existing model class (the view model) to the different parts of the UI or view.

  • Workarounds for supporting MVVM in the Silverlight ContextMenu service

    As I discussed in my last post, some of the Silverlight controls does not support MVVM quite well out of the box without specific customizations. The Context Menu is another control that requires customizations for enabling data binding on the menu options. There are a few things that you might want to expose as view model for a menu item, such as the Text, the associated icon or the command that needs to be executed. That view model should look like this,