In place navigation and regions

Topics: Prism v4 - Silverlight 4, Prism v4 - WPF 4
Dec 2, 2011 at 10:38 AM

Goal: I want all my views (viewmodels) to be able to do in place view switching (independent of the regions (navigation) behavior) and also implement some mechanism to return some values to the previous view on removing the view (kind of a dialog box but inplace and not blocking the app, just the view below it).

Problem: When you create a region associated with a tab control, then when a view in a tab navigates to the same (current) region, a new tab will be created instead of being overlaid with a new view.


You have an order view in which you need to select a customer. This customer selection could implemented in some module. When clicking on some button "Select Customer" a new view appears over the current view, and after selecting a customer, that selected customer is returned to the previous view (/ viewmodel).

Question: What are the best ways to accomplish this with prism.


Kind regards,








Dec 2, 2011 at 3:40 PM


You could do this

  • Create a region in the tab
  • load your order view in it
  • when clicking on Select Customer, load the module (using modulemanager) where the select customer view is and then navigate to the view using region navigation.
  • once done navigate back to the order view

In effect you are in the same tab. Is this what you are looking for?

Dec 5, 2011 at 12:32 PM

Technically that would work.

But what name would you give your region. If you want to use a fixed name (to make code independent of it), than one also have to create a nested regionmanager. If you don't , the other tab pages would also create the same region name which is not allowed.

How can the viewmodel be injected with the "current" regionmanager ?

I assume that it is best to encapsulate this behavior in some Service.

Would this not be something you would expect prism to provide out of the box ?