Learning Silverlight: Day Four

HMS_Surprise_large

Day Three concluded with finishing the QuickStart series on Building Dynamic User Interfaces with Silverlight, from the official Silverlight website.  Day Four continues with notes and unsolicited errata on Networking and Communication in Silverlight.

A. Sending and Receiving Plain XML Messages with Silverlight — I learned a new acronym in this very brief tutorial.  POX stands for plain ol’ XML.  The System.Net.WebClient class allows us to call a web service (in this case, a DIGG service) and pass the results to a callback method.

B. Building a WCF Web Service and Accessing It by Using a Proxy — Very nice.  A somewhat sophisticated small application combining Silverlight and WCF, explained clearly.  Someone went through and proofread this particular walkthrough, and the effort shows even in the details — like stating what namespaces need to be referenced before one actually needs to use them.

C. Accessing Syndication Feeds with Silverlight — Very simple tutorial on how to access an rss feed in Silverlight using the System.ServiceModel.Syndication.SyndicationFeed class.  The only problem is that if you follow the instructions precisely, it will not work.  The sample code uses the Silverlight.net rss feed, http://silverlight.net/blogs/microsoft/rss.aspx, as its source.  Unfortunately, in order to access an rss feed, the server hosting the feed must have a policy file set up to allow cross-domain access, which the Silverlight.net rss feed does not.

A tad annoying, no?  Or perhaps this is a some sort of Zen exercise intended to reinforce the principle that a Clientaccesspolicy.xml or Crossdomain.xml file must always be properly configured on the feed server. 

2 thoughts on “Learning Silverlight: Day Four”

Leave a Reply

Your email address will not be published. Required fields are marked *