5
votes

Is it possible to use two ViewModels for a single View at MvvmCross?

The reason is an existing Core library which already has navigation in place and a working app on top of it. Now I need to create another app and leverage the only View for two ViewModels (in core lib there is one view navigated to another using ShowViewModel and I just want to stay at the same view and change my datacontext).

Thank you for any suggestions.

1

1 Answers

5
votes

Yes

  • you can continue to use ShowViewModel and change the way navigation happens by overriding the presenter - see Custom Presenters in the wiki
  • or you can use a different navigation mechanism entirely - there's nothing forcing you to use ShowViewModel