I’m starting to train Prism (CAL) with a small application and faced some problems.
I’m creating multiple instances of my MainView, which itself contains some regions, and display them in the Shell.
I’m using locally scoped regions to easily handle view injections within my MainView.
Currently I’m searching for a way of communication between the views (viewModels) inside the MainView. Composite events could do it, but when I publish those events, they are handled in all instances of my MainView, which I really don’t want.
Is there a way of raising “locally scoped” composite events like with locally scoped regions? Or may be there’s a better way of communicating between views in my case?
Pass form sender as an argument. (Anyway, there must be a way to distinguish your application’s windows – use it.) When you recieve the event, check whether current form ReferenceEquals to sender (Or, check the form ‘key’).