I created my UserControl
like this:
MyUserCtrl myctrl = new MyUserCtrl() { DataContext = new MyViewModel()};
ControlCollection.Add(myctrl);
and i output it using this ItemsControl ItemsSource="{Binding ControlCollection}"
to the View.
It's clean and nice but the problem is I don't know how can I close those UserControls
that I opened.
And what if I just remove it to the collection. Thus the View Model will close too?