Mahesh Sabnis explores how to share data across XAPs hosted on the same .aspx page using the LocalConnection API in Silverlight 3.
I recently came across a requirement on exchanging data between two XAPs hosted in single .NET page. In this article we will discuss one of the most important features of Silverlight 3.0 that is ‘LocalConnectionAPI’. In Silverlight 3.0, the following new classes were introduced:
· LocalMessageSender : This is the sending end of the message channel.
· LocalMessageReceiver: This is the receiving end of the messaging channel.
Using the following steps we can implement LocalConnection with Silverlight.