Custom Markup Extension

There are 1 entries for the tag Custom Markup Extension
Pairing View and ViewModel using Silverlight5 Custom Markup Extension

I’m a longtime supporter of Laurent Bugnion’s MVVM Light Toolkit and I love using it together with my favorite IOC Container NInject, one of the most “boring” area is creating the class that exposes ViewModel instances in a design time way: the famous ViewModelLocator class. Now that Silverlight5 has custom markup extensions I thought: what about using it to simplify View vs ViewModel lookup? Here’s my attempt, let’s start with a simple ViewModel (nothing really new here, just to give you a complete scenario) public class...

posted @ venerdì 6 maggio 2011 09:56 | Feedback (0)