SL 3 Local Messaging and Prism

Topics: Prism v2 - Silverlight 3
Aug 24, 2009 at 9:16 AM

First, sorry for this potential stupid question as I'm new in Silverlight and Prism.

I'm a bit confuse. Silverlight 3 offer the new functionnality to communicate with other SL application

on the same page, on a different TAB or even a different browser using Local Messaging functionnality.


What would be the difference with EVENTAGREGATOR inside a prism application ?

Could we use Prism to load dynamically module (SL sub applications) and then use SL3 Messages to communicate through module/application ?


Thanks in advance,


Aug 25, 2009 at 7:57 PM

Hi Christophe, 

The Prism EventAggregator and the Silverlight 3 Local messaging are similar concepts, but still they are different. Basically SL3 is target to communicate different SL applications while prism EA is meant to resolve communication between modules in a decoupled fashion.

You can take only prism module loading and still use SL3 LM without problems. You can even extend the default prism event aggregator to use Silverlight 3 messaging underneath.
Some of the differences I can think of, that might help you decide which fits better in your scenario: 

  1. Prism EA uses typed payloads while SL3 LM accepts only strings.
  2. SL3 LM focus on communication between different SL apps. Prism EA does not communicate different applications.
  3. Prism EA can be used either on SL and WPF (multi-targeted applications)

Hope it helps!

Matias Bonaventura

Aug 26, 2009 at 2:34 PM
Edited Aug 26, 2009 at 3:06 PM

Hi Matias,

Thanks for your quick response :) !

I see more clear now, and Local Messaging don't fit my need. But...

In the meantime, I found new info and I'm even more lost. I read about Prism, MEF and MAF (System.Addin).

I'm in trouble to find which way to use, as those three technos could even work togheter.


My app is an Silverlight Navigation Application.

One page is a kind of dashboard that would contain buttons to run some plugin/module, or shortcuts to another XAP.

Those plugin/modules will be displayed in a page container, the page itself will be displayed in the FRAME container of the Navigation Application.

I read (and tested) that Prism Region are available only if the shell is set as the rootvisual of the main App, and that not's fine with my app (as it's already a navigation app).


I think I'll go for MEF to implement modularity, with a combination of MAF to load/unload modules in a separate AppDomain. Or I could use only MAF. I don't know.
As I said, I'm lost even after three days reading articles about those topics :)

BY chance, do you have more info/advices ?

Thanks (again :) )


 [EDIT] I've just read that MAF is not possible with Silverlight. Too bad....