Take into account that when calling the region's Remove method you have to pass the
object view that was added to the region's collection, and not the wrapper window like in your case (which is passed through the
For example, based on my understanding of your scenario your code could be like this:
private void ContentDialogClosed(object sender, System.EventArgs e)
In this case, I retrieved the view from the Content property of the wrapper window. Take into account, that you have to do this before calling the
CloseContentDialog method, as it will end up setting the
Content property to null.
Also, note that I'm using the Region property of the
RegionBehavior to remove the view, as it's not required to retrieve the
RegionManager instance from the container.
I hope you find this handy,