views:

389

answers:

2

I have an existing Silverlight application where Page.xaml has some buttons on it that load user controls into a TransitioningContentControl content host. Each of these user controls is bound to a viewmodel. Sometimes when changes are made to one user control, data in others would need to be updated. I have been looking at using the event aggregator in Prism but don't really want to have to convert everything to a shell, modules etc. Is there any way for me to add event aggregation without going to Prism?

+3  A: 

You can use the EventAggregator from Prism on its own - no changes to your application are required to accommodate it - or you could use an alternative such as Messenger from the MVVM Light Toolkit. Links to further alternatives and discussion can be found on Jeremy D. Miller's blog.

GraemeF
I've used (different) bits of PRISM in my own projects. You can just use their DLLs or, since you get the source code, just lift the bits you need and add them to your own project.
ssg31415926
I will give it a try using just the event aggregator from Prism. Thanks for your answer.
DaveB
+1  A: 

You can find one example here at Event Aggregation QuickStart

funwithcoding