Soped Region

May 1, 2010 at 5:06 AM


I want to add a module which has sub modules and repeat the module three times

So, let's say I want to add module called Customer, and add three sub modules in the Customer View, which they are Billing, Account, Address

those sub modules will be added as tabcontrol.

So in the Customer View I am adding a tab control and define the region regions:RegionManager.RegionName="CustomerDetailsData"

and as I said, I am repeating the module "Customer" three times.

When I load the application, it gives error creating the second customer module, because "CustomerDetailsData" already exist.


Any idea how to do that?


May 5, 2010 at 5:26 PM


A possible approach, as you mention in your questions title, would be adding each CustomerView in a scoped region manager. This will prevent having a duplicated region name in your application’s “root” RegionManager. This article from the Prism documentation explains how to add a view and create a scoped RegionManager. You might also be interested in this thread, where Guido Maliandi provides some useful pointers for dealing with multiple RegionManager instances.

Please let me know if this helps.

Damian Schenkelman

May 14, 2010 at 3:14 PM

In a similar scenario we have used child containers for each Customer Dashboard. In that case we dont have to worry about named instances of region managers and any other object for that matter.