This project is read-only.

NavigateAction to View Model with generic type definition possible

Feb 6, 2011 at 3:07 PM


I would like to use the NavigateAction to navigate to a view which has an associated VM that has a generic type definition, is this possible as I can't see how I can pass "T"?




public class WidgetConfigurationViewModel<T> : NavigationViewModelBase{}

Thanks in advance for any help.



Feb 8, 2011 at 12:36 AM

Without going into more complex/advanced ways of doing so, you can simply define the ViewModel on the View itself, like so:

public partial class MailWidgetConfigurationView : UserControl

or alternatively use DefineViewViewModel to achieve the same.