<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Jim O'Neil's Blog : Silverlight</title><link>http://blogs.msdn.com/jimoneil/archive/tags/Silverlight/default.aspx</link><description>Tags: Silverlight</description><dc:language>en-US</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>Discovering Dallas: Part 3</title><link>http://blogs.msdn.com/jimoneil/archive/2009/12/21/discovering-dallas-part-3.aspx</link><pubDate>Mon, 21 Dec 2009 11:17:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9939028</guid><dc:creator>joneil</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/jimoneil/comments/9939028.aspx</comments><wfw:commentRss>http://blogs.msdn.com/jimoneil/commentrss.aspx?PostID=9939028</wfw:commentRss><description>&lt;P&gt;This is the final post of a trifecta examining &lt;A href="http://www.microsoft.com/windowsazure/developers/dallas/" mce_href="http://www.microsoft.com/windowsazure/developers/dallas/"&gt;Microsoft “Dallas”&lt;/A&gt;, a marketplace for data &lt;IMG style="BORDER-RIGHT-WIDTH: 0px; MARGIN: 25px 0px 5px 15px; DISPLAY: inline; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px" title="" border=0 alt="" align=right src="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/DiscoveringDallasPart3_18D2/image_15.png" width=240 height=89 mce_src="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/DiscoveringDallasPart3_18D2/image_15.png" dallas??="Dallas??"&gt;services announced at &lt;A href="http://microsoftpdc.com/" mce_href="http://microsoftpdc.com"&gt;PDC 2009&lt;/A&gt;.&amp;nbsp; In my &lt;A href="http://blogs.msdn.com/jimoneil/archive/2009/11/30/discovering-dallas.aspx" mce_href="http://blogs.msdn.com/jimoneil/archive/2009/11/30/discovering-dallas.aspx"&gt;first post&lt;/A&gt;, I provided an overview of “Dallas”, including how to access various trial data services via the developer portal and in code.&amp;nbsp; &lt;/P&gt;
&lt;P&gt;I &lt;A href="http://blogs.msdn.com/jimoneil/archive/2009/12/14/discovering-dallas-part-2.aspx" mce_href="http://blogs.msdn.com/jimoneil/archive/2009/12/14/discovering-dallas-part-2.aspx"&gt;followed that up last week with a post&lt;/A&gt; that walks through modifying the auto-generated C# service proxy classes to provide asynchronous invocation capabilities, a must have for Silverlight client access and, in general, a good way to go to keep your application UI responsive in the face of slow or unpredictable network performance.&lt;/P&gt;
&lt;P&gt;For this article, I’m going to leverage the code changes I made in the last article (to enable asynchronous access) to build a Silverlight application that accesses the same &lt;A href="http://data.gov/" mce_href="http://data.gov"&gt;Data.gov&lt;/A&gt; crime statistics that the previous Windows Forms application did.&amp;nbsp; As I mentioned &lt;A href="http://blogs.msdn.com/jimoneil/archive/2009/12/14/discovering-dallas-part-2.aspx" mce_href="http://blogs.msdn.com/jimoneil/archive/2009/12/14/discovering-dallas-part-2.aspx"&gt;in that post&lt;/A&gt;, Silverlight has two primary constraints in terms of accessing resources and services over the web:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Access must be asynchronous, and &lt;/LI&gt;
&lt;LI&gt;Resources must be accessed from the point-of-origin of the Silverlight application (although there are options we’ll discuss next for working around this). &lt;/LI&gt;&lt;/UL&gt;
&lt;H2&gt;Handling Cross-Domain Access&lt;/H2&gt;
&lt;P&gt;Asynchronous access was addressed in the last post, so now we need to deal with enabling Silverlight applications downloaded from my web host to access services hosted on “Dallas”, namely the api.sqlazureservices.com domain.&amp;nbsp; With Silverlight there are two ways to handle this:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Use a proxy; that is, set up a service hosted on the same domain as my Silverlight application that acts as a go-between to the “Dallas” service.&amp;nbsp; The Silverlight application is talking to a service that’s at its point-of-origin, and that service is a simple client to the ultimate service hosted by “Dallas.”&amp;nbsp; Although it forces an extra hop in the communication chain, it’s a fairly common pattern for handling the ‘point-of-origin’ constraint. &lt;BR&gt;&lt;BR&gt;&lt;/LI&gt;
&lt;LI&gt;Set up a policy file on the service host, here api.sqlazureservices.com.&amp;nbsp; Before attempting to access a non point-of-origin service, a Silverlight application will check to see if the targeted server has a &lt;A href="http://msdn.microsoft.com/en-us/library/cc645032(VS.95).aspx#sectionToggle1" mce_href="http://msdn.microsoft.com/en-us/library/cc645032(VS.95).aspx#sectionToggle1"&gt;clientaccesspolicy.xml file&lt;/A&gt; at the root of its domain.&amp;nbsp; This file is an XML document containing information on what clients are allowed access to the server and what resources on the server they can access.&amp;nbsp; If a clientaccesspolicy.xml file is not found, Silverlight will then look for a &lt;A href="http://www.adobe.com/devnet/articles/crossdomain_policy_file_spec.html" mce_href="http://www.adobe.com/devnet/articles/crossdomain_policy_file_spec.html"&gt;crossdomain.xml file&lt;/A&gt;, which is an XML file used for similar purposes by Adobe Flash applications. &lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;“Dallas” has just recently setup up a clientaccesspolicy.xml file (below) to permit Silverlight application access, so that’s the route I’m going to pursue here.&amp;nbsp; The complete format of the file is &lt;A href="http://msdn.microsoft.com/en-us/library/cc645032(VS.95).aspx" mce_href="http://msdn.microsoft.com/en-us/library/cc645032(VS.95).aspx"&gt;described in the MSDN documentation&lt;/A&gt;, but the salient features required for “Dallas” include:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Line 5 – specification of the request headers that are sent by the client.&amp;nbsp; If the client includes headers not specified here, the request is rejected.&amp;nbsp; The headers sent are, of course, the $accountKey and the $uniqueUserID. &lt;/LI&gt;
&lt;LI&gt;Lines 6-7 – specification of the client URLs allowed access.&amp;nbsp; Since “Dallas” is accessible only via HTTPS, the domain tags are necessary to enable a Silverlight application downloaded via HTTP to access the “Dallas” server. &lt;/LI&gt;
&lt;LI&gt;Line 10 – specification of which resources (URIs) the client can access on the “Dallas” server; here, it’s everything below the domain root. &lt;/LI&gt;&lt;/UL&gt;
&lt;DIV&gt;
&lt;DIV style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px" id=codeSnippet&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: white; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;&lt;SPAN style="COLOR: #606060" id=lnum1&gt;   1:&lt;/SPAN&gt; &lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;?&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;xml&lt;/SPAN&gt; &lt;SPAN style="COLOR: #ff0000"&gt;version&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="1.0"&lt;/SPAN&gt; &lt;SPAN style="COLOR: #ff0000"&gt;encoding&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="utf-8"&lt;/SPAN&gt; ?&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt; &lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;&lt;SPAN style="COLOR: #606060" id=lnum2&gt;   2:&lt;/SPAN&gt; &lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;access-policy&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: white; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;&lt;SPAN style="COLOR: #606060" id=lnum3&gt;   3:&lt;/SPAN&gt;    &lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;cross-domain-access&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;&lt;SPAN style="COLOR: #606060" id=lnum4&gt;   4:&lt;/SPAN&gt;       &lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;policy&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: white; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;&lt;SPAN style="COLOR: #606060" id=lnum5&gt;   5:&lt;/SPAN&gt;          &lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;allow-from&lt;/SPAN&gt; &lt;SPAN style="COLOR: #ff0000"&gt;http-request-headers&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="$accountKey,$uniqueUserID"&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;&lt;SPAN style="COLOR: #606060" id=lnum6&gt;   6:&lt;/SPAN&gt;             &lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;domain&lt;/SPAN&gt; &lt;SPAN style="COLOR: #ff0000"&gt;uri&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="http://*"&lt;/SPAN&gt; &lt;SPAN style="COLOR: #0000ff"&gt;/&amp;gt;&lt;/SPAN&gt; &lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: white; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;&lt;SPAN style="COLOR: #606060" id=lnum7&gt;   7:&lt;/SPAN&gt;             &lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;domain&lt;/SPAN&gt; &lt;SPAN style="COLOR: #ff0000"&gt;uri&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="https://*"&lt;/SPAN&gt; &lt;SPAN style="COLOR: #0000ff"&gt;/&amp;gt;&lt;/SPAN&gt; &lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;&lt;SPAN style="COLOR: #606060" id=lnum8&gt;   8:&lt;/SPAN&gt;          &lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;allow-from&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: white; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;&lt;SPAN style="COLOR: #606060" id=lnum9&gt;   9:&lt;/SPAN&gt;          &lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;grant-to&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;&lt;SPAN style="COLOR: #606060" id=lnum10&gt;  10:&lt;/SPAN&gt;             &lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;resource&lt;/SPAN&gt; &lt;SPAN style="COLOR: #ff0000"&gt;path&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="/"&lt;/SPAN&gt; &lt;SPAN style="COLOR: #ff0000"&gt;include-subpaths&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="true"&lt;/SPAN&gt; &lt;SPAN style="COLOR: #0000ff"&gt;/&amp;gt;&lt;/SPAN&gt; &lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: white; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;&lt;SPAN style="COLOR: #606060" id=lnum11&gt;  11:&lt;/SPAN&gt;          &lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;grant-to&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;&lt;SPAN style="COLOR: #606060" id=lnum12&gt;  12:&lt;/SPAN&gt;      &lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;policy&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: white; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;&lt;SPAN style="COLOR: #606060" id=lnum13&gt;  13:&lt;/SPAN&gt;    &lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;cross-domain-access&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;&lt;SPAN style="COLOR: #606060" id=lnum14&gt;  14:&lt;/SPAN&gt; &lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;access-policy&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;/DIV&gt;&lt;/DIV&gt;
&lt;H2&gt;A Few More Tweaks&lt;/H2&gt;
&lt;P&gt;At this point, you’d figure it would just work; we’ve got code to make an asynchronous call, and the cross-domain access issue is resolved via the policy file, right?&amp;nbsp;&amp;nbsp; Well, not quite.&amp;nbsp; &lt;/P&gt;
&lt;P&gt;Silverlight runs on the CLR, but it’s a subset of the full-blown .NET CLR (one that fits within a 5MB or so download).&amp;nbsp; When I built the asynchronous invocation code in the &lt;A href="http://blogs.msdn.com/jimoneil/archive/2009/12/14/discovering-dallas-part-2.aspx" mce_href="http://blogs.msdn.com/jimoneil/archive/2009/12/14/discovering-dallas-part-2.aspx"&gt;previous post&lt;/A&gt;, I did so for a Windows Forms application, and when pulling that same code into my Silverlight application, I ended up with a few compilation issues.&lt;/P&gt;
&lt;OL&gt;
&lt;LI&gt;In the code that converts the XML (Atom format) response stream into the data transfer object class (DataGovCrimeByCitiesItem), the static method &lt;A href="http://msdn.microsoft.com/en-us/library/system.convert.changetype.aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.convert.changetype.aspx"&gt;Convert.ChangeType&lt;/A&gt; is frequently invoked.&amp;nbsp; In Silverlight, that method has fewer overloads than in the full .NET Framework, so I had to add a final parameter value (null) to each of the calls.&amp;nbsp; That parameter is a IFormatProvider, which in this case is inconsequential since we are not presenting the data in this step. &lt;BR&gt;&lt;BR&gt;Now, that same issue exists in the auto-generated code for the synchronous invocation as well (along with some additional issues).&amp;nbsp; In Silverlight though, the synchronous invocation is not an option, so you’ll need to comment out or otherwise remove the Invoke and InvokeWebService methods that are part of the C# code generated when you select the &lt;EM&gt;Download C# service classes…&lt;/EM&gt; option on the “Dallas” Developer Portal. &lt;BR&gt;&lt;BR&gt;&lt;/LI&gt;
&lt;LI&gt;The code that assigned the $accountKey and $uniqueUserID to the HTTP Request header looks like this in my first attempt: &lt;/LI&gt;&lt;/OL&gt;
&lt;BLOCKQUOTE&gt;
&lt;DIV id=codeSnippetWrapper&gt;
&lt;DIV style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px" id=codeSnippet&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: white; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;request.Headers.Add(&lt;SPAN style="COLOR: #006080"&gt;"$accountKey"&lt;/SPAN&gt;,&lt;SPAN style="COLOR: #0000ff"&gt;this&lt;/SPAN&gt;.AccountKey);&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;request.Headers.Add(&lt;SPAN style="COLOR: #006080"&gt;"$uniqueUserID"&lt;/SPAN&gt;, &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #0000ff"&gt;this&lt;/SPAN&gt;.UniqueUserID.ToString());&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/BLOCKQUOTE&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;Unfortunately, Silverlight does not support the Add method on a &lt;A href="http://msdn.microsoft.com/en-us/library/system.net.webheadercollection(VS.95).aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.net.webheadercollection(VS.95).aspx"&gt;WebHeaderCollection&lt;/A&gt;, but the remedy is rather simple:&lt;/P&gt;
&lt;DIV id=codeSnippetWrapper&gt;
&lt;DIV style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px" id=codeSnippet&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: white; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;request.Headers[&lt;SPAN style="COLOR: #006080"&gt;"$accountKey"&lt;/SPAN&gt;] = &lt;SPAN style="COLOR: #0000ff"&gt;this&lt;/SPAN&gt;.AccountKey;&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;request.Headers[&lt;SPAN style="COLOR: #006080"&gt;"$uniqueUserID"&lt;/SPAN&gt;] = &lt;SPAN style="COLOR: #0000ff"&gt;this&lt;/SPAN&gt;.UniqueUserID.ToString();&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/BLOCKQUOTE&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;With that, the code compiles just fine, but at runtime you’ll get a System.NotSupportedException with the less than helpful message that “Specified method is not supported” and pointing to the line:&lt;/P&gt;
&lt;DIV id=codeSnippetWrapper&gt;
&lt;DIV style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px" id=codeSnippet&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: white; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;HttpWebResponse response = (HttpWebResponse)request.EndGetResponse(ar);&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;/DIV&gt;&lt;/DIV&gt;
&lt;H2&gt;Using the Silverlight Client stack&lt;/H2&gt;
&lt;P&gt;Well, certainly &lt;A href="http://msdn.microsoft.com/en-us/library/system.net.httpwebrequest.endgetresponse(VS.95).aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.net.httpwebrequest.endgetresponse(VS.95).aspx"&gt;EndGetResponse&lt;/A&gt; is supported in Silverlight – after all &lt;A href="http://msdn.microsoft.com/en-us/library/system.net.httpwebrequest.endgetresponse(VS.95).aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.net.httpwebrequest.endgetresponse(VS.95).aspx"&gt;MSDN says so&lt;/A&gt;, and it would be tough to make asynchronous calls (the only type allowed) if it weren’t.&amp;nbsp; What’s happening here is that restrictions in the browser HTTP stack, which Silverlight leverages by default, prevents the call from succeeding.&amp;nbsp; The reason is somewhat &lt;A href="http://msdn.microsoft.com/en-us/library/cc838250(VS.95).aspx" mce_href="http://msdn.microsoft.com/en-us/library/cc838250(VS.95).aspx"&gt;buried in the MSDN documentation&lt;/A&gt;:&lt;/P&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;&lt;EM&gt;You can send headers, if they are allowed per the client access policy file, by setting the &lt;/EM&gt;&lt;A href="http://msdn.microsoft.com/en-us/library/system.net.httpwebrequest.headers(VS.95).aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.net.httpwebrequest.headers(VS.95).aspx"&gt;&lt;EM&gt;HttpWebRequest.Headers&lt;/EM&gt;&lt;/A&gt;&lt;EM&gt; property. If you are sending headers on anything other than POST requests, you must use Client HTTP handling.&lt;/EM&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;While we took care of the client access policy file, the existing code to create the request&lt;/P&gt;
&lt;DIV id=codeSnippetWrapper&gt;
&lt;DIV style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px" id=codeSnippet&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: white; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;HttpWebRequest request =&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;    (HttpWebRequest) HttpWebRequest.Create(&lt;SPAN style="COLOR: #0000ff"&gt;new&lt;/SPAN&gt; Uri(builder.ToString()));&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: white; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;request.Headers[&lt;SPAN style="COLOR: #006080"&gt;"$accountKey"&lt;/SPAN&gt;] = &lt;SPAN style="COLOR: #0000ff"&gt;this&lt;/SPAN&gt;.AccountKey;&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;request.Headers[&lt;SPAN style="COLOR: #006080"&gt;"$uniqueUserID"] = &lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;this&lt;/SPAN&gt;.UniqueUserID.ToString();&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;/DIV&gt;&lt;/DIV&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;defaults to &lt;EM&gt;browser HTTP handling&lt;/EM&gt;, and since the default HTTP verb here is a GET &lt;EM&gt;&lt;STRONG&gt;and&lt;/STRONG&gt;&lt;/EM&gt; we’re setting headers to pass in the $accountKey and $uniqueUserID, we’re doomed to failure.&lt;/P&gt;
&lt;P&gt;You might be inclined to change the request type to a POST via the &lt;A href="http://msdn.microsoft.com/en-us/library/system.net.httpwebrequest.method(VS.95).aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.net.httpwebrequest.method(VS.95).aspx"&gt;request.Method&lt;/A&gt; property, but that will result in an HTTP 405 (Method not allowed) error since the “Dallas” service is not configured to accept POST requests.&amp;nbsp; That leads to the only other option here, using Client HTTP handling.&amp;nbsp; &lt;/P&gt;
&lt;P&gt;Client HTTP handling was introduced with Silverlight 3 and provides additional HTTP support over the default browser handling, including REST service calls, use of HTTP verbs other than GET and POST, and support for additional status codes.&amp;nbsp; To opt in to client HTTP handling, you create the WebRequest using the &lt;A href="http://msdn.microsoft.com/en-us/library/system.net.browser.webrequestcreator.clienthttp(VS.95).aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.net.browser.webrequestcreator.clienthttp(VS.95).aspx"&gt;ClientHttp&lt;/A&gt; property of the &lt;A href="http://msdn.microsoft.com/en-us/library/system.net.browser.webrequestcreator(VS.95).aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.net.browser.webrequestcreator(VS.95).aspx"&gt;WebRequestCreator&lt;/A&gt; static class, so the HttpWebRequest instantiation code directly above would be modified to&lt;/P&gt;
&lt;DIV id=codeSnippetWrapper&gt;
&lt;DIV style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px" id=codeSnippet&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: white; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;HttpWebRequest request = (HttpWebRequest)&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;    System.Net.Browser.WebRequestCreator.ClientHttp.Create(&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: white; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;        &lt;SPAN style="COLOR: #0000ff"&gt;new&lt;/SPAN&gt; Uri(builder.ToString()));&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;!--CRLF--&gt;&lt;!--CRLF--&gt;&lt;/DIV&gt;&lt;/DIV&gt;
&lt;P&gt;With that last change, the Silverlight example executes successfully:&lt;/P&gt;
&lt;P&gt;&lt;IMG style="BORDER-RIGHT-WIDTH: 0px; DISPLAY: inline; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px" title='Silverlight "Dallas" example' border=0 alt='Silverlight "Dallas" example' src="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/DiscoveringDallasPart3_18D2/image_3.png" width=528 height=382 mce_src="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/DiscoveringDallasPart3_18D2/image_3.png"&gt; &lt;/P&gt;
&lt;H2&gt;Code Reuse&lt;/H2&gt;
&lt;P&gt;With the modification of the code above to use the Silverlight Client HTTP stack, I’ve now complicated my code base.&amp;nbsp; The non-Silverlight scenarios (WPF, Windows Forms, etc.) can’t use this code – they won’t even compile – because the &lt;A href="http://msdn.microsoft.com/en-us/library/system.net.browser(VS.95).aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.net.browser(VS.95).aspx"&gt;System.Net.Browser&lt;/A&gt; namespace is Silverlight only.&amp;nbsp;&amp;nbsp; As a result I need two different calls to instantiate the request depending on the runtime context of the application.&lt;/P&gt;
&lt;P&gt;One option to resolve this is compiler directives, where the HttpWebRequest creation depends on the compilation environment.&amp;nbsp; This works fine for Silverlight 3 since Silverlight and non-Silverlight assemblies are not binary compatible – meaning you need to recompile the code anyway.&lt;/P&gt;
&lt;DIV id=codeSnippetWrapper&gt;
&lt;DIV style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px" id=codeSnippet&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: white; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;&lt;SPAN style="COLOR: #cc6633"&gt;#if&lt;/SPAN&gt; SILVERLIGHT&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;    HttpWebRequest request = (HttpWebRequest)&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: white; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;        System.Net.Browser.WebRequestCreator.ClientHttp.Create(&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;            &lt;SPAN style="COLOR: #0000ff"&gt;new&lt;/SPAN&gt; Uri(builder.ToString()));&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: white; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;&lt;SPAN style="COLOR: #cc6633"&gt;#else&lt;/SPAN&gt;&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;    HttpWebRequest request = (HttpWebRequest)&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: white; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;        WebRequest.Create(&lt;SPAN style="COLOR: #0000ff"&gt;new&lt;/SPAN&gt; Uri(builder.ToString()));&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px"&gt;&lt;SPAN style="COLOR: #cc6633"&gt;#endif&lt;/SPAN&gt;&lt;/PRE&gt;&lt;!--CRLF--&gt;&lt;/DIV&gt;&lt;/DIV&gt;
&lt;P&gt;In Silverlight 4 though, Microsoft announced binary compatibility of Silverlight with non-Silverlight assemblies, so the compiler directive isn’t as attractive a feature.&lt;/P&gt;
&lt;P&gt;Other alternatives exist though, such as using the &lt;A href="http://msdn.microsoft.com/en-us/library/system.net.webrequest.registerprefix(VS.95).aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.net.webrequest.registerprefix(VS.95).aspx"&gt;WebRequest.RegisterPrefix&lt;/A&gt; method to map some or all Silverlight requests to the Client HTTP stack.&amp;nbsp; This initialization need be made only once (say in the constructor of the service class) and then the &lt;A href="http://msdn.microsoft.com/en-us/library/system.net.webrequest.create.aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.net.webrequest.create.aspx"&gt;WebRequest.Create&lt;/A&gt; code will automatically use the Client versus the Browser HTTP stack.&amp;nbsp; Then, there’s no longer a need for the compiler directive in the code above (although a similar scenario arises when calling RegisterPrefix).&lt;/P&gt;
&lt;P&gt;You could probably obviate the use of the compiler directive using reflection too.&amp;nbsp; Additionally, Dependency Injection (say using &lt;A href="http://www.codeplex.com/unity" mce_href="http://www.codeplex.com/unity"&gt;Unity&lt;/A&gt;) is perhaps a more elegant option, but certainly adds more complexity to the application.&amp;nbsp; Given that “Dallas” is still a work in progress, and it’s likely that the release version will have a more robust implementation for the service classes, I’ll resist the temptation to over-engineer and leave it to the real developers in Redmond to work it all out for the public release!&lt;/P&gt;
&lt;H2&gt;Sample Code&lt;/H2&gt;
&lt;P&gt;&lt;A href="http://blogs.msdn.com/jimoneil/attachment/9939028.ashx" mce_href="http://blogs.msdn.com/jimoneil/attachment/9939028.ashx"&gt;I’ve posted the code discussed&lt;/A&gt; above, along with the updated version of the Windows Forms example that uses the same service class implementation.&amp;nbsp; Of course, to run it you’ll still need to &lt;A href="http://www.microsoft.com/windowsazure/developers/dallas/" mce_href="http://www.microsoft.com/windowsazure/developers/dallas/"&gt;get your own Dallas token&lt;/A&gt;.&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9939028" width="1" height="1"&gt;</description><enclosure url="http://blogs.msdn.com/jimoneil/attachment/9939028.ashx" length="43988" type="application/x-zip-compressed" /><category domain="http://blogs.msdn.com/jimoneil/archive/tags/Silverlight/default.aspx">Silverlight</category><category domain="http://blogs.msdn.com/jimoneil/archive/tags/Dallas/default.aspx">Dallas</category></item><item><title>PDC: Pretty Darn Cool!</title><link>http://blogs.msdn.com/jimoneil/archive/2009/11/21/pdc-pretty-darn-cool.aspx</link><pubDate>Sat, 21 Nov 2009 18:18:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9926777</guid><dc:creator>joneil</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/jimoneil/comments/9926777.aspx</comments><wfw:commentRss>http://blogs.msdn.com/jimoneil/commentrss.aspx?PostID=9926777</wfw:commentRss><description>&lt;p&gt;&lt;img style="border-bottom: 0px; border-left: 0px; margin: 0px 0px 0px 10px; display: inline; border-top: 0px; border-right: 0px" title="PDC" border="0" alt="PDC" align="right" src="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/PDCPrettyDarnCool_BB43/11-21-2009%2012-38-03%20PM_3.gif" width="136" height="186" /&gt; &lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;I got back from &lt;a href="http://microsoftpdc.com"&gt;PDC&lt;/a&gt; yesterday and have managed to (mostly) make up for my sleep deficit.&amp;#160; Undoubtedly you’ve heard by now some of the major announcements at the conference (including the &lt;a href="http://channel9.msdn.com/posts/LarryLarsen/The-Great-PDC-Laptop-Give-Away-of-2009/"&gt;free multi-touch laptop&lt;/a&gt; that all the paying attendees received!):&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;a href="http://silverlight.net/getstarted/silverlight-4-beta/"&gt;Silverlight 4&lt;/a&gt;&lt;/p&gt;    &lt;p&gt;&lt;a href="http://www.microsoft.com/windowsazure/"&gt;Windows Azure availability&lt;/a&gt;&lt;/p&gt;    &lt;p&gt;&lt;a href="http://www.microsoft.com/windowsazure/developers/dallas/"&gt;“Dallas”&lt;/a&gt;&lt;/p&gt;    &lt;p&gt;&lt;a href="http://www.microsoft.com/office/2010/en/default.aspx?WT.srch=1&amp;amp;WT.mc_id=FDC76082-09CC-47FF-9ABD-1E0ED70C6A94"&gt;Office 2010 Beta&lt;/a&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;If you haven’t already, be sure to listen to the two keynotes (&lt;a href="http://microsoftpdc.com/Sessions/KEY01"&gt;Day 1&lt;/a&gt; and &lt;a href="http://microsoftpdc.com/Sessions/KEY02"&gt;Day 2&lt;/a&gt;) to see how far things have come since PDC 08 (as well as where we’re headed).&amp;#160; The sessions are also &lt;a href="http://microsoftpdc.com/Videos"&gt;available on demand&lt;/a&gt;, so you can experience all of the content from the comfort of your own living room as well!&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9926777" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/jimoneil/archive/tags/Silverlight/default.aspx">Silverlight</category><category domain="http://blogs.msdn.com/jimoneil/archive/tags/PDC/default.aspx">PDC</category></item><item><title>See the (Silver)Light</title><link>http://blogs.msdn.com/jimoneil/archive/2009/07/10/see-the-silver-light.aspx</link><pubDate>Fri, 10 Jul 2009 20:30:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9827517</guid><dc:creator>joneil</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/jimoneil/comments/9827517.aspx</comments><wfw:commentRss>http://blogs.msdn.com/jimoneil/commentrss.aspx?PostID=9827517</wfw:commentRss><description>&lt;p&gt;&lt;a href="http://www.seethelight.com/"&gt;&lt;img style="border-right-width: 0px; margin: 0px 15px 0px 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="Silverlight 3" border="0" alt="Silverlight 3" align="left" src="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/SeetheSilverLight_FCC6/Web%20Ad_120x240_SeeTheLight_3.jpg" width="120" height="240" /&gt;&lt;/a&gt;Today marks the release-to-web (RTW) of Silverlight 3 as well as the release candidate of Expression Blend 3.&lt;/p&gt;  &lt;p&gt;You’ve heard of the cool and innovative new features and maybe even caught our recent &lt;a href="http://blogs.msdn.com/cbowen/archive/2009/07/06/summer-northeast-roadshow-resources-and-wrapup.aspx"&gt;Roadshow&lt;/a&gt; where &lt;a href="http://blogs.msdn.com/cbowen"&gt;Chris&lt;/a&gt; demonstrated many of them – smooth streaming, SketchFlow, out-of-browser applications, communications between Silverlight applications, and more.&lt;/p&gt;  &lt;p&gt;Now follow the &lt;a href="http://www.seethelight.com/"&gt;launch activities&lt;/a&gt; or check out the links below for more information on how to take your applications to the next level!&lt;/p&gt;  &lt;blockquote&gt;   &lt;blockquote&gt;     &lt;blockquote&gt;       &lt;ul&gt;         &lt;li&gt;&lt;a href="http://team.silverlight.net/"&gt;Silverlight blog&lt;/a&gt; &lt;/li&gt;          &lt;li&gt;&lt;a href="https://login.live.com/login.srf?wa=wsignin1.0&amp;amp;rpsnv=10&amp;amp;ct=1246917234&amp;amp;rver=5.0.3265.0&amp;amp;wp=MCMBI&amp;amp;wreply=https:%2F%2Fprofile.microsoft.com%2FRegSysProfileCenter%2Fwizard.aspx%3Fwizid%3Db62e5f03-3188-474a-a5f4-ff0116a3ccaa%26lcid%3D1033&amp;amp;lc=1033&amp;amp;cb=LCID%3D1033%26WizID%3Db62e5f03-3188-474a-a5f4-ff0116a3ccaa%26brand%3DMicrosoft&amp;amp;id=74335"&gt;Expression newsletter&lt;/a&gt; &lt;/li&gt;       &lt;/ul&gt;&lt;/blockquote&gt;&lt;/blockquote&gt;&lt;/blockquote&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9827517" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/jimoneil/archive/tags/Silverlight/default.aspx">Silverlight</category></item><item><title>Summer of Silverlight – Win $10K</title><link>http://blogs.msdn.com/jimoneil/archive/2009/07/07/summer-of-silverlight-win-10k.aspx</link><pubDate>Tue, 07 Jul 2009 17:00:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9820593</guid><dc:creator>joneil</dc:creator><slash:comments>1</slash:comments><comments>http://blogs.msdn.com/jimoneil/comments/9820593.aspx</comments><wfw:commentRss>http://blogs.msdn.com/jimoneil/commentrss.aspx?PostID=9820593</wfw:commentRss><description>&lt;p&gt;&lt;img style="border-right-width: 0px; margin: 5px 10px 5px 15px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="Win $10000" border="0" alt="Win $10000" align="right" src="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/SummerofSilverlightWin10K_EA48/image_10.png" width="145" height="145" /&gt;I missed the mark on this one, but thanks to a recent posting from &lt;a href="http://weblogs.asp.net/despos/archive/2009/07/02/silverlight-coding-contest.aspx"&gt;Dino Esposito&lt;/a&gt;, I just became aware of ComponentArt’s &lt;a href="http://www.componentart.com/community/competition2009/"&gt;2009 Summer Silverlight Coding Competition&lt;/a&gt;.&amp;#160; &lt;/p&gt;  &lt;p&gt;The best application (as selected by the panel and community votes) will win $10,000, and two-runners up will receive ComponentArt licenses.&amp;#160; Use of ComponentArt products is &lt;strong&gt;&lt;em&gt;NOT&lt;/em&gt;&lt;/strong&gt; required.&amp;#160; Applications will start appearing for community voting today, but you have through September 22 to submit your entries.&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9820593" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/jimoneil/archive/tags/Silverlight/default.aspx">Silverlight</category><category domain="http://blogs.msdn.com/jimoneil/archive/tags/Fun/default.aspx">Fun</category></item><item><title>Awesome WPF/Silverlight Guidance</title><link>http://blogs.msdn.com/jimoneil/archive/2009/06/12/awesome-wpf-silverlight-guidance.aspx</link><pubDate>Fri, 12 Jun 2009 21:38:45 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9737194</guid><dc:creator>joneil</dc:creator><slash:comments>2</slash:comments><comments>http://blogs.msdn.com/jimoneil/comments/9737194.aspx</comments><wfw:commentRss>http://blogs.msdn.com/jimoneil/commentrss.aspx?PostID=9737194</wfw:commentRss><description>&lt;p&gt;I don’t casually throw around words like ‘awesome', but this is indeed it.&amp;#160; If you’re building applications for WPF and/or Silverlight, you’ve certainly become XAMLized, since XAML (eXtensible Markup Language) is the “common” user-interface description markup.&amp;#160;&amp;#160; Well, more-or-less “common”.&amp;#160; Both technologies use XAML, but the level of support has subtle nuances, and things that are supported on WPF may not be supported on Silverlight (though 99% of Silverlight is supported by WPF).&amp;#160; It’s not always obvious what the nuances are, and like me, you may have discovered them empirically – and uttered a few words of frustration not printable here.&lt;/p&gt;  &lt;p&gt;The good news is that WPF and Silverlight are aligning, so “we feel your pain,” and the development process and support will continue to converge.&amp;#160; Until we reach that nirvana though, the &lt;a href="http://wpfslguidance.codeplex.com/Release/ProjectReleases.aspx?ReleaseId=28278"&gt;WPF-Silverlight Comparison Whitepaper&lt;/a&gt; is a MUST read for anyone embarking on (or currently developing) WPF and Silverlight applications.&amp;#160; It’s a comprehensive 69-page document on just those nuances between the technologies that we prefer to know about before designing and coding – versus after!&lt;/p&gt;  &lt;p&gt;The document was produced by our friends at &lt;a href="http://wintellect.com/"&gt;Wintellect&lt;/a&gt; at the behest of Microsoft, and is, well, an awesome reference for developers in this space.&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9737194" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/jimoneil/archive/tags/Silverlight/default.aspx">Silverlight</category><category domain="http://blogs.msdn.com/jimoneil/archive/tags/WPF/default.aspx">WPF</category></item><item><title>Atta Boy, Andy</title><link>http://blogs.msdn.com/jimoneil/archive/2009/05/29/atta-boy-andy.aspx</link><pubDate>Fri, 29 May 2009 07:31:30 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9651730</guid><dc:creator>joneil</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/jimoneil/comments/9651730.aspx</comments><wfw:commentRss>http://blogs.msdn.com/jimoneil/commentrss.aspx?PostID=9651730</wfw:commentRss><description>&lt;p&gt;Congrats to the Northeast’s own &lt;a href="http://www.andybeaulieu.com/"&gt;Andy Beaulieu&lt;/a&gt; (MVP and leader of the &lt;a href="http://cnydevelopers.net"&gt;Central New York .NET Developer Group&lt;/a&gt;) for winning the &lt;a href="http://www.serverquestcontest.com"&gt;ServerQuest II&lt;/a&gt; Silverlight game competition, with his entry &lt;a href="http://spritehand.com/silverlight/2.0/BossLaunch/BossLaunch.htm"&gt;Boss Launch&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;&lt;a href="http://spritehand.com/silverlight/2.0/BossLaunch/BossLaunch.htm"&gt;&lt;img style="border-right-width: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto" title="Click here for Boss Launch!" border="0" alt="Click here for Boss Launch!" src="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/AttaBoyAndy_739/image_3.png" width="479" height="257" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;And from the “great timing department”, my colleague, &lt;a href="http://blogs.msdn.com/glengordon"&gt;Glen Gordon&lt;/a&gt;, and I had the privilege of chatting with Andy just yesterday about Silverlight gaming on &lt;a href="http://blogs.msdn.com/geekspeak/"&gt;GeekSpeak&lt;/a&gt;; you can &lt;a href="http://msevents.microsoft.com/CUI/WebCastEventDetails.aspx?culture=en-US&amp;amp;EventID=1032414973&amp;amp;CountryCode=US"&gt;download the recorded session here&lt;/a&gt;. &lt;/p&gt;  &lt;p&gt;You can check out other bits of Andy’s work at &lt;a href="http://www.spritehand.com"&gt;http://www.spritehand.com…&lt;/a&gt; but don’t let the boss catch you!&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9651730" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/jimoneil/archive/tags/Silverlight/default.aspx">Silverlight</category><category domain="http://blogs.msdn.com/jimoneil/archive/tags/New+York/default.aspx">New York</category><category domain="http://blogs.msdn.com/jimoneil/archive/tags/Fun/default.aspx">Fun</category></item><item><title>NERD to Host XAML Fest - May 27th - 28th</title><link>http://blogs.msdn.com/jimoneil/archive/2009/05/11/nerd-to-host-xaml-fest-may-27th-28th.aspx</link><pubDate>Tue, 12 May 2009 01:04:53 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9604755</guid><dc:creator>joneil</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/jimoneil/comments/9604755.aspx</comments><wfw:commentRss>http://blogs.msdn.com/jimoneil/commentrss.aspx?PostID=9604755</wfw:commentRss><description>&lt;p&gt;&lt;img style="border-right-width: 0px; margin: 0px 20px 5px 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" border="0" align="left" src="http://blogs.msdn.com/blogfiles/usisvde/WindowsLiveWriter/JoinforXAMLFestOnlineJune15_ECA0/xamlfest_2.png" /&gt;My colleague, John Pelak, is bringing &lt;a href="http://blogs.msdn.com/usisvde/archive/2009/05/05/you-re-invited-to-xamlfest-boston-may-27-may-28.aspx"&gt;another edition of the XAML Fest&lt;/a&gt; series to the Boston area, this time to Microsoft’s &lt;a href="http://www.microsoftcambridge.com"&gt;New England Research and Development Center&lt;/a&gt; (aka NERD) in Cambridge.&amp;#160; The past several sessions in this area filled to capacity quickly, and like those sessions we’re limiting attendance to provide an effective hands-on learning experience… in other words, don’t delay in signing up!&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;By the way, this is revamped content in light of announcements at &lt;a href="http://live.visitmix.com/"&gt;MIX 09&lt;/a&gt;, so content now includes Expression Blend 3, Silverlight 3, and other cool features that were announced in March.&amp;#160; John has all the details, agenda, and a FAQ &lt;a href="http://blogs.msdn.com/usisvde/archive/2009/05/05/you-re-invited-to-xamlfest-boston-may-27-may-28.aspx"&gt;at his blog post&lt;/a&gt;, but here are the particulars on registration and venue.&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;table border="0" cellspacing="0" cellpadding="2" width="399" align="center"&gt;&lt;tbody&gt;     &lt;tr&gt;       &lt;td valign="top" width="71"&gt;&lt;strong&gt;Date:&lt;/strong&gt;&lt;/td&gt;        &lt;td valign="top" width="326"&gt;Wed. May 27 and Thur. 28, 2009&lt;/td&gt;     &lt;/tr&gt;      &lt;tr&gt;       &lt;td valign="top" width="71"&gt;&lt;strong&gt;Time:&lt;/strong&gt;&lt;/td&gt;        &lt;td valign="top" width="326"&gt;9 a.m. – 5 p.m.&lt;/td&gt;     &lt;/tr&gt;      &lt;tr&gt;       &lt;td valign="top" width="71"&gt;&lt;strong&gt;Place:&lt;/strong&gt;&lt;/td&gt;        &lt;td valign="top" width="326"&gt;&lt;a href="http://www.microsoftcambridge.com"&gt;Microsoft NERD&lt;/a&gt;           &lt;br /&gt;1 Memorial Drive           &lt;br /&gt;Cambridge, MA&lt;/td&gt;     &lt;/tr&gt;      &lt;tr&gt;       &lt;td valign="top" width="71"&gt;&lt;strong&gt;Cost:&lt;/strong&gt;&lt;/td&gt;        &lt;td valign="top" width="326"&gt;Free (vouchers available for on-site parking)&lt;/td&gt;     &lt;/tr&gt;      &lt;tr&gt;       &lt;td valign="top" width="71"&gt;&lt;strong&gt;Register:&lt;/strong&gt;&lt;/td&gt;        &lt;td valign="top" width="326"&gt;e-mail &lt;a href="mailto:xamlfest-boston@live.com"&gt;xamlfest-boston@live.com&lt;/a&gt;           &lt;br /&gt;(include name and e-mail of attendees)&lt;/td&gt;     &lt;/tr&gt;   &lt;/tbody&gt;&lt;/table&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;If you can’t make the live edition, then you’re still in luck.&amp;#160; &lt;em&gt;XAMLFest online&lt;/em&gt;, a combination of live and recorded content, hits the airwaves from June 1st through the 5th.&amp;#160; You can &lt;a href="http://blogs.msdn.com/usisvde/archive/2009/05/10/join-for-xamlfest-recorded-sessions-online-live-june-1-5.aspx"&gt;read more about the scheduling and registration here&lt;/a&gt;.&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9604755" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/jimoneil/archive/tags/Silverlight/default.aspx">Silverlight</category><category domain="http://blogs.msdn.com/jimoneil/archive/tags/Massachusetts/default.aspx">Massachusetts</category><category domain="http://blogs.msdn.com/jimoneil/archive/tags/WPF/default.aspx">WPF</category></item><item><title>RIA = Developer + Designer</title><link>http://blogs.msdn.com/jimoneil/archive/2009/04/20/ria-developer-designer.aspx</link><pubDate>Mon, 20 Apr 2009 23:39:08 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9557274</guid><dc:creator>joneil</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/jimoneil/comments/9557274.aspx</comments><wfw:commentRss>http://blogs.msdn.com/jimoneil/commentrss.aspx?PostID=9557274</wfw:commentRss><description>&lt;p&gt;That’s an equation you’ll typically hear us evangelists espouse, with &lt;a href="http://msdn.microsoft.com/en-us/library/ms752059.aspx"&gt;XAML&lt;/a&gt; (eXtensible Application Markup Language) being the &lt;em&gt;lingua franca&lt;/em&gt; of the developer/designer relationship, and Visual Studio and Expression Studio the tools of choice.&amp;#160; It’s a compelling story and one that’s easy to talk about, but face it, in my role, I mostly talk-the-talk, and it’s you guys that have to walk-the-walk.&lt;/p&gt;  &lt;p&gt;&lt;a href="http://www.cynergysystems.com"&gt;&lt;/a&gt;&lt;a href="http://www.cynergysystems.com/"&gt;&lt;img style="border-right-width: 0px; margin: 15px 0px 5px 10px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="image" border="0" alt="image" align="right" src="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/RIADeveloperDesigner_EA1B/image_3.png" width="240" height="75" /&gt;&lt;/a&gt;&lt;/a&gt; Well, if anyone walks-the-walk, it’s &lt;a href="http://www.cynergysystems.com"&gt;Cynergy Systems&lt;/a&gt;, whose hallmark is RIA, whether it be with WPF and Silverlight or &lt;a href="http://www.adobe.com"&gt;those other guys&lt;/a&gt;.&amp;#160; A recent &lt;a href="http://www.forrester.com/Research/Document/Excerpt/0,7211,54243,00.html"&gt;Forrester Research Case Study&lt;/a&gt; profiles Cynergy’s roots and approach to building software in this emerging space.&amp;#160; &lt;/p&gt;  &lt;p&gt;In a pretty amazing move, Cynergy announced it is providing the seven-page report &lt;strong&gt;&lt;em&gt;free&lt;/em&gt;&lt;/strong&gt; to the community (&lt;a href="http://www.cynergysystems.com/blogs/page/davewolf?entry=how_do_you_do_ria"&gt;details in Dave Wolf’s blog post&lt;/a&gt;).&amp;#160; It’s a great read, and technology-agnostic, so focuses on how to approach developing RIA solutions versus the specific tools and technologies that you might employ to deliver them.&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9557274" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/jimoneil/archive/tags/Silverlight/default.aspx">Silverlight</category><category domain="http://blogs.msdn.com/jimoneil/archive/tags/WPF/default.aspx">WPF</category></item><item><title>Silverlight 3 Emerges from the Shadows</title><link>http://blogs.msdn.com/jimoneil/archive/2009/03/18/silverlight-3-emerges-from-the-shadows.aspx</link><pubDate>Wed, 18 Mar 2009 20:10:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9485730</guid><dc:creator>joneil</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/jimoneil/comments/9485730.aspx</comments><wfw:commentRss>http://blogs.msdn.com/jimoneil/commentrss.aspx?PostID=9485730</wfw:commentRss><description>&lt;p&gt;&lt;a href="http://www.silverlight.net"&gt;&lt;img style="border-right-width: 0px; margin: 0px 15px 20px 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="Silverlight" border="0" alt="Silverlight" align="left" src="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/Silverlight3_14D2D/Silverlight%20h%20c%20reverse_3.png" width="188" height="61" /&gt;&lt;/a&gt; Scott Guthrie gave a bit of a teaser in a blog post &lt;a href="http://weblogs.asp.net/scottgu/archive/2008/11/16/update-on-silverlight-2-and-a-glimpse-of-silverlight-3.aspx"&gt;last November&lt;/a&gt;, but today Silverlight 3 is a significant step closer to reality through the official announcement of &lt;a href="http://silverlight.net"&gt;a beta release&lt;/a&gt; at &lt;a href="http://2009.visitmix.com/"&gt;MIX 09&lt;/a&gt; in Las Vegas.&amp;#160; Coinciding with the beta is the availability of a preview of Expression Blend 3.&lt;/p&gt;  &lt;p&gt;So what’s coming down the pike in Silverlight 3?&amp;#160; Well, the big news is the availability of Silverlight outside of the browser.&amp;#160; This means you’ll be able to deploy Silverlight applications to the desktop without need for an additional&amp;#160; runtime or download.&amp;#160; Add to that over 50 new features and productivity improvements, including&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;&lt;strong&gt;Support for H.264 video and AAC audio playback&lt;/strong&gt; &lt;/li&gt;    &lt;li&gt;&lt;strong&gt;Perspective 3D&lt;/strong&gt; – Via an extension of the 2D API already in Silverlight 2, you’ll now be able to add perspective to your visual presentations to provide a near-3D experience. &lt;/li&gt;    &lt;li&gt;&lt;strong&gt;Built-in and custom shader effects&lt;/strong&gt; – As in WPF, you’ll be able to provide effects like blur and drop-shadow as well as custom effects that utilize Microsoft’s High Level Shader Language (HLSL). &lt;/li&gt;    &lt;li&gt;&lt;strong&gt;GPU acceleration&lt;/strong&gt; – Through caching of the visual tree as a bitmap, Silverlight 3 will be able to make better use of the GPU for certain effects, thus freeing up the CPU for other work. &lt;/li&gt;    &lt;li&gt;&lt;strong&gt;Element name binding&lt;/strong&gt; – This brings the binding model of Silverlight more in line with that of WPF by allowing the property of one UI element to be bound to the property of another. &lt;/li&gt;    &lt;li&gt;&lt;strong&gt;Styling improvements&lt;/strong&gt; – With Silverlight 3 you can now build styles that are based on other styles as well as reset styles at runtime (both are options that are also available now in WPF). &lt;/li&gt;    &lt;li&gt;&lt;strong&gt;Binding validation&lt;/strong&gt; – With Silverlight 3, validation is now available in two-way binding scenarios for data entered via the UI before it is transmitted to the binding source.&amp;#160; As in WPF, UI validation templates will also be provided. &lt;/li&gt;    &lt;li&gt;&lt;strong&gt;Multi-select list box&lt;/strong&gt; – This control is but one of 60+ fully customizable controls available across nine professionally designed themes (complete with source code to use as is or modify to your heart’s content). &lt;/li&gt;    &lt;li&gt;&lt;strong&gt;Application library caching&lt;/strong&gt; – Framework assemblies are cached on the client and reused across application invocations or instances, thus improving performance and reducing the collective application footprint. &lt;/li&gt;    &lt;li&gt;&lt;strong&gt;Local connections&lt;/strong&gt; – Silverlight applications running on the client can communicate with each other without requiring a server round-trip. &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;That’s just a quick-and-dirty list, there’s definitely more, including &lt;a href="http://mmod.ncaa.com/"&gt;&lt;img style="border-right-width: 0px; margin: 15px 0px 0px 20px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="March Madness 2009" border="0" alt="March Madness 2009" align="right" src="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/Silverlight3_14D2D/image_3.png" width="125" height="127" /&gt;&lt;/a&gt;extensible logging, more options for From-To animations (like spring and bounce), deep linking, improved text rendering and font support, and a File Save dialog.&lt;/p&gt;  &lt;p&gt;By the way, the NCAA has chosen Silverlight 2 to provide the high quality, on-demand coverage for &lt;a href="http://mmod.ncaa.com/"&gt;March Madness&lt;/a&gt;.&amp;#160; And you don’t have to wait until tomorrow – there’s some historical highlights as well, including &lt;a href="http://mmod.ncaa.com/video/hq?ts=1237260555&amp;amp;t=30f555baefa3e0b7d05e2ea145cee60b&amp;amp;w=90"&gt;Laettner’s amazing last second shot&lt;/a&gt; in the 1992 East regional final versus Kentucky… not that I’m a Dukie or anything!&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9485730" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/jimoneil/archive/tags/Silverlight/default.aspx">Silverlight</category><category domain="http://blogs.msdn.com/jimoneil/archive/tags/MIX/default.aspx">MIX</category></item><item><title>Get into the MIX09</title><link>http://blogs.msdn.com/jimoneil/archive/2009/03/04/get-into-the-mix09.aspx</link><pubDate>Wed, 04 Mar 2009 18:43:37 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9458609</guid><dc:creator>joneil</dc:creator><slash:comments>1</slash:comments><comments>http://blogs.msdn.com/jimoneil/comments/9458609.aspx</comments><wfw:commentRss>http://blogs.msdn.com/jimoneil/commentrss.aspx?PostID=9458609</wfw:commentRss><description>&lt;p&gt;It’s exactly two weeks until &lt;a href="http://2009.visitmix.com/"&gt;MIX09&lt;/a&gt;, and here’s the scene from my home office window juxtaposed with one of the MIX09 venue.&amp;#160; Vegas is looking pretty good, huh?&lt;/p&gt;  &lt;table border="0" cellspacing="0" cellpadding="5" align="center"&gt;&lt;tbody&gt;     &lt;tr&gt;       &lt;td valign="top" width="200"&gt;&lt;a href="http://www.weather.com/weather/local/01720"&gt;&lt;img style="border-right-width: 0px; margin: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="Will Winter never end?" border="0" alt="Will Winter never end?" src="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/GetintotheMIX09_96D1/DSCN0843_1.jpg" width="180" height="240" /&gt;&lt;/a&gt;&lt;/td&gt;        &lt;td valign="top" width="200"&gt;&lt;a href="http://www.venetian.com/"&gt;&lt;img style="border-right-width: 0px; margin: 0px; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="O solo mio!" border="0" alt="O solo mio!" src="http://newton.typepad.com/content/images/2007/03/23/venetian.jpg" width="288" height="237" /&gt;&lt;/a&gt;&lt;/td&gt;     &lt;/tr&gt;   &lt;/tbody&gt;&lt;/table&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;Weather aside, there’s a lot of other great things in store at this year’s edition of *the* conference focused on next generation web, rich internet applications, and the collaboration between developers and designers.&lt;/p&gt;  &lt;p&gt;&lt;a href="http://2009.visitmix.com/"&gt;&lt;img style="border-right-width: 0px; margin: 0px 15px 0px 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="image" border="0" alt="image" align="left" src="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/GetintotheMIX09_96D1/image_3.png" width="240" height="54" /&gt;&lt;/a&gt; There’s nearly &lt;a href="https://content.visitmix.com/2009/sessions/?categories=Silverlight"&gt;30 sessions on Silverlight&lt;/a&gt; alone, including not one, not two, but three on what’s in store with Silverlight 3.&amp;#160; There’s quite a few on ASP.NET MVC as well (for which &lt;a href="http://www.microsoft.com/downloads/details.aspx?FamilyID=ee4b2e97-8a72-449a-82d2-2f720d421031&amp;amp;displaylang=en"&gt;RC2 was made available&lt;/a&gt; last night).&amp;#160; Add to that Azure, Live Services, UI/UX, and you’ve got about &lt;a href="https://content.visitmix.com/2009/sessions/"&gt;10 dozen sessions&lt;/a&gt; to choose from.&lt;/p&gt;  &lt;p&gt;Check out the MIX09 site and schedule your &lt;strike&gt;vacation&lt;/strike&gt; training now!&amp;#160; And if you can’t be there, join Chris, Bob, and me on the &lt;a href="http://blogs.msdn.com/jimoneil/archive/2009/02/16/northeast-roadshow-march-madness-edition.aspx"&gt;Northeast Roadshow&lt;/a&gt;.&amp;#160; We’ll actually be in Hartford and Augusta while MIX is going on.&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9458609" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/jimoneil/archive/tags/Silverlight/default.aspx">Silverlight</category><category domain="http://blogs.msdn.com/jimoneil/archive/tags/MVC/default.aspx">MVC</category><category domain="http://blogs.msdn.com/jimoneil/archive/tags/WPF/default.aspx">WPF</category><category domain="http://blogs.msdn.com/jimoneil/archive/tags/MIX/default.aspx">MIX</category><category domain="http://blogs.msdn.com/jimoneil/archive/tags/ASP.NET/default.aspx">ASP.NET</category></item><item><title>I is for… Isolated Storage</title><link>http://blogs.msdn.com/jimoneil/archive/2009/03/02/i-is-for-isolated-storage.aspx</link><pubDate>Mon, 02 Mar 2009 08:00:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9453307</guid><dc:creator>joneil</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/jimoneil/comments/9453307.aspx</comments><wfw:commentRss>http://blogs.msdn.com/jimoneil/commentrss.aspx?PostID=9453307</wfw:commentRss><description>&lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/IisforImplicit_14018/i_2.gif"&gt;&lt;img style="border-right-width: 0px; margin: 0px 15px 10px 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="i" border="0" alt="i" align="left" src="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/IisforImplicit_14018/i_thumb.gif" width="49" height="75" /&gt;&lt;/a&gt;Isolated storage is a pretty nifty concept that’s actually been part of the .NET Framework since version 1.1 but is getting a bit more attention these days with the adoption of Silverlight and the desire to leverage the client machine for a better user experience. Since Silverlight is a browser-based technology, you can’t just do things like access the file system, because that would break the “sandbox” model.&amp;#160; &lt;/p&gt;  &lt;p&gt;Enter isolated storage.&amp;#160; In a nutshell, you can think of it as your own private (well, relatively) virtual file system.&amp;#160; An &lt;code&gt;IsolatedStorageFile&lt;/code&gt; instance is essentially a container for directories and files associated with the current user and Silverlight application (or, optionally, web site).&amp;#160;&amp;#160; It’s intended as a way to store small bits of non-vital information associated with the application, like user-preferences.&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;em&gt;Note, isolated storage is also part of the full .NET framework (to support Click-Once applications, for instance).&amp;#160; The implementation for Silverlight, which is the focus of this post, is a subset of that functionality.&amp;#160; Consult the &lt;/em&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/3ak841sy.aspx"&gt;&lt;em&gt;MSDN documentation&lt;/em&gt;&lt;/a&gt;&lt;em&gt; if you want more insight into capabilities of isolated storage on the full .NET Framework.&amp;#160; Documentation on the &lt;a href="http://msdn.microsoft.com/en-us/library/system.io.isolatedstorage(VS.95).aspx"&gt;Silverlight-specific implementation of isolated storage can be found on MSDN here&lt;/a&gt;.&lt;/em&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;Here are some of the key characteristics of isolated storage:&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;It’s managed by the .NET runtime.&amp;#160; You don’t specify where the isolated file store is stored on the disk; the runtime handles it, but it is part of the file system, typically under the AppData folder of your user profile, and so is discoverable.&amp;#160; Hence, you don’t want use isolated storage for information that is required for your application to operate or thast contains sensitive information. &lt;/li&gt; &lt;/ul&gt;  &lt;ul&gt;   &lt;li&gt;There’s a 1MB default limit, although this can be increased if the client allows it.&amp;#160; &lt;a href="#quota"&gt;See how here&lt;/a&gt;. &lt;/li&gt; &lt;/ul&gt;  &lt;ul&gt;   &lt;li&gt;Storage is always associated with a particular user, and an application run by one user cannot access another’s storage.&amp;#160; A given user, however, can be outfitted with unique isolated storage instances for each application (&lt;code&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/system.io.isolatedstorage.isolatedstoragefile.getuserstoreforapplication(VS.95).aspx"&gt;GetUserStoreForApplication&lt;/a&gt;&lt;/code&gt;) and&amp;#160; a separate store shared by all applications served from a given site (&lt;code&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/system.io.isolatedstorage.isolatedstoragefile.getuserstoreforsite(VS.95).aspx"&gt;GetUserStoreForSite&lt;/a&gt;&lt;/code&gt;). &lt;/li&gt; &lt;/ul&gt;  &lt;ul&gt;   &lt;li&gt;Unlike the browser cache, isolated storage is persistent.&amp;#160; The application can delete files or directories via methods of &lt;code&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/system.io.isolatedstorage.isolatedstoragefile_members(VS.95).aspx"&gt;IsolatedStorageFile&lt;/a&gt;&lt;/code&gt;, and of course, the storage file could be removed by the user directly, via File Explorer for instance. &lt;/li&gt; &lt;/ul&gt;  &lt;ul&gt;   &lt;li&gt;You can use streams and serialization techniques to read and write data just as you do for a conventional file system. &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;Let’s work through a (contrived) sample, and you’ll get an idea of how easy it really is.&amp;#160; I have a Silverlight application with two buttons which change the foreground color and background color respectively.&amp;#160; Here’s a ‘before-and-after’ picture.&lt;/p&gt;  &lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/IisforImplicit_14018/image_2.png"&gt;&lt;img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="image" border="0" alt="image" src="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/IisforImplicit_14018/image_thumb.png" width="227" height="129" /&gt;&lt;/a&gt; &lt;a href="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/IisforImplicit_14018/image_4.png"&gt;&lt;img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="image" border="0" alt="image" src="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/IisforImplicit_14018/image_thumb_1.png" width="234" height="132" /&gt;&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;The code for this application is pretty simple:&lt;/p&gt;  &lt;div class="csharpcode"&gt;   &lt;pre class="alt"&gt;&lt;span class="kwrd"&gt;public&lt;/span&gt; &lt;span class="kwrd"&gt;partial&lt;/span&gt; &lt;span class="kwrd"&gt;class&lt;/span&gt; Page : UserControl&lt;/pre&gt;

  &lt;pre&gt;{ &lt;/pre&gt;

  &lt;pre class="alt"&gt;    &lt;span class="kwrd"&gt;public&lt;/span&gt; Page()&lt;/pre&gt;

  &lt;pre&gt;    {&lt;/pre&gt;

  &lt;pre class="alt"&gt;        InitializeComponent();&lt;/pre&gt;

  &lt;pre&gt;        cbBackground.Click += &lt;span class="kwrd"&gt;new&lt;/span&gt; RoutedEventHandler(cbBackground_Click);&lt;/pre&gt;

  &lt;pre class="alt"&gt;        cbForeground.Click += &lt;span class="kwrd"&gt;new&lt;/span&gt; RoutedEventHandler(cbForeground_Click);&lt;/pre&gt;

  &lt;pre&gt;    }&lt;/pre&gt;

  &lt;pre class="alt"&gt;&amp;#160;&lt;/pre&gt;

  &lt;pre&gt;    &lt;span class="kwrd"&gt;void&lt;/span&gt; cbForeground_Click(&lt;span class="kwrd"&gt;object&lt;/span&gt; sender, RoutedEventArgs e)&lt;/pre&gt;

  &lt;pre class="alt"&gt;    {&lt;/pre&gt;

  &lt;pre&gt;        txtHello.Foreground = &lt;span class="kwrd"&gt;new&lt;/span&gt; SolidColorBrush(GetRandomColor());&lt;/pre&gt;

  &lt;pre class="alt"&gt;    }&lt;/pre&gt;

  &lt;pre&gt;&amp;#160;&lt;/pre&gt;

  &lt;pre class="alt"&gt;    &lt;span class="kwrd"&gt;void&lt;/span&gt; cbBackground_Click(&lt;span class="kwrd"&gt;object&lt;/span&gt; sender, RoutedEventArgs e)&lt;/pre&gt;

  &lt;pre&gt;    {&lt;/pre&gt;

  &lt;pre class="alt"&gt;        gridLayout.Background = &lt;span class="kwrd"&gt;new&lt;/span&gt; SolidColorBrush(GetRandomColor());&lt;/pre&gt;

  &lt;pre&gt;    }&lt;/pre&gt;

  &lt;pre class="alt"&gt;&amp;#160;&lt;/pre&gt;

  &lt;pre&gt;    &lt;span class="kwrd"&gt;private&lt;/span&gt; Color GetRandomColor()&lt;/pre&gt;

  &lt;pre class="alt"&gt;    {&lt;/pre&gt;

  &lt;pre&gt;        Random r = &lt;span class="kwrd"&gt;new&lt;/span&gt; Random((&lt;span class="kwrd"&gt;int&lt;/span&gt;)System.DateTime.Now.Ticks);&lt;/pre&gt;

  &lt;pre class="alt"&gt;        Color c = &lt;span class="kwrd"&gt;new&lt;/span&gt; Color();&lt;/pre&gt;

  &lt;pre&gt;        c.A = 255;&lt;/pre&gt;

  &lt;pre class="alt"&gt;        c.R = (&lt;span class="kwrd"&gt;byte&lt;/span&gt;)r.Next(255);&lt;/pre&gt;

  &lt;pre&gt;        c.G = (&lt;span class="kwrd"&gt;byte&lt;/span&gt;)r.Next(255);&lt;/pre&gt;

  &lt;pre class="alt"&gt;        c.B = (&lt;span class="kwrd"&gt;byte&lt;/span&gt;)r.Next(255);&lt;/pre&gt;

  &lt;pre&gt;        &lt;span class="kwrd"&gt;return&lt;/span&gt; c;&lt;/pre&gt;

  &lt;pre class="alt"&gt;    }&lt;/pre&gt;

  &lt;pre&gt;}&lt;/pre&gt;
&lt;/div&gt;
&lt;style type="text/css"&gt;

































.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }&lt;/style&gt;

&lt;p&gt;The default experience is black text and a white background, but I want repeat visitors to retain their last set of color choices when they re-launch the application.&lt;/p&gt;

&lt;p&gt;To save the color choices, I’ll make use of isolated storage.&amp;#160; In the ‘real’ world, I’d probably use XML serialization to save my preferences, but here I’m taking the easy way out, and will store the colors as two hex strings representing the foreground color and background colors, respectively.&amp;#160; For instance, the following contents would indicate opaque red text on a blue background:&lt;/p&gt;

&lt;pre&gt;    FFFF0000    
    FF0000FF&lt;/pre&gt;

&lt;p&gt;&lt;font size="3"&gt;&lt;strong&gt;Reading from Isolated Storage&lt;/strong&gt;&lt;/font&gt;&lt;/p&gt;

&lt;p&gt;To the program above, I’ve added some logic to read from the preferences file, &lt;code&gt;colors.txt&lt;/code&gt;, in isolated storage.&amp;#160; Then I’ve set the foreground and background colors to the values read in (lines 10-12, below):&lt;/p&gt;

&lt;div class="csharpcode"&gt;
  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;   1:  &lt;/span&gt;&lt;span class="kwrd"&gt;public&lt;/span&gt; &lt;span class="kwrd"&gt;partial&lt;/span&gt; &lt;span class="kwrd"&gt;class&lt;/span&gt; Page : UserControl&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;   2:  &lt;/span&gt;{&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;   3:  &lt;/span&gt;    Color foreColor;&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;   4:  &lt;/span&gt;    Color backColor;&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;   5:  &lt;/span&gt;&amp;#160;&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;   6:  &lt;/span&gt;    &lt;span class="kwrd"&gt;public&lt;/span&gt; Page()&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;   7:  &lt;/span&gt;    {&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;   8:  &lt;/span&gt;        InitializeComponent();&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;   9:  &lt;/span&gt;&amp;#160;&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;  10:  &lt;/span&gt;        LoadColors(&lt;span class="kwrd"&gt;out&lt;/span&gt; foreColor, &lt;span class="kwrd"&gt;out&lt;/span&gt; backColor);&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;  11:  &lt;/span&gt;        txtHello.Foreground = &lt;span class="kwrd"&gt;new&lt;/span&gt; SolidColorBrush(foreColor);&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;  12:  &lt;/span&gt;        gridLayout.Background = &lt;span class="kwrd"&gt;new&lt;/span&gt; SolidColorBrush(backColor);&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;  13:  &lt;/span&gt;&amp;#160;&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;  14:  &lt;/span&gt;        cbBackground.Click += &lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;  15:  &lt;/span&gt;            &lt;span class="kwrd"&gt;new&lt;/span&gt; RoutedEventHandler(cbBackground_Click);&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;  16:  &lt;/span&gt;        cbForeground.Click += &lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;  17:  &lt;/span&gt;            &lt;span class="kwrd"&gt;new&lt;/span&gt; RoutedEventHandler(cbForeground_Click);&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;  18:  &lt;/span&gt;    }&lt;/pre&gt;
&lt;/div&gt;
&lt;style type="text/css"&gt;






























.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }&lt;/style&gt;&lt;style type="text/css"&gt;
































.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }&lt;/style&gt;&lt;style type="text/css"&gt;
































.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }&lt;/style&gt;

&lt;p&gt;Here’s my implementation of &lt;code&gt;LoadColors&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;div class="csharpcode"&gt;
  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;   1:  &lt;/span&gt;&lt;span class="kwrd"&gt;public&lt;/span&gt; &lt;span class="kwrd"&gt;void&lt;/span&gt; LoadColors(&lt;span class="kwrd"&gt;out&lt;/span&gt; Color f, &lt;span class="kwrd"&gt;out&lt;/span&gt; Color b)&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;   2:  &lt;/span&gt;{&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;   3:  &lt;/span&gt;    &lt;span class="kwrd"&gt;string&lt;/span&gt; foreStr = &lt;span class="str"&gt;&amp;quot;00000000&amp;quot;&lt;/span&gt;;&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;   4:  &lt;/span&gt;    &lt;span class="kwrd"&gt;string&lt;/span&gt; backStr = &lt;span class="str"&gt;&amp;quot;FFFFFFFF&amp;quot;&lt;/span&gt;;&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;   5:  &lt;/span&gt;&amp;#160;&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;   6:  &lt;/span&gt;    &lt;span class="kwrd"&gt;using&lt;/span&gt; (IsolatedStorageFile isf = &lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;   7:  &lt;/span&gt;              IsolatedStorageFile.GetUserStoreForApplication())&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;   8:  &lt;/span&gt;    {&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;   9:  &lt;/span&gt;        &lt;span class="kwrd"&gt;try&lt;/span&gt;&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;  10:  &lt;/span&gt;        {&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;  11:  &lt;/span&gt;            &lt;span class="kwrd"&gt;using&lt;/span&gt; (IsolatedStorageFileStream str = isf.OpenFile&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;  12:  &lt;/span&gt;                    (&lt;span class="str"&gt;&amp;quot;colors.txt&amp;quot;&lt;/span&gt;, FileMode.Open, FileAccess.Read))&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;  13:  &lt;/span&gt;            {&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;  14:  &lt;/span&gt;                StreamReader reader = &lt;span class="kwrd"&gt;new&lt;/span&gt; StreamReader(str);&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;  15:  &lt;/span&gt;                foreStr = reader.ReadLine();&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;  16:  &lt;/span&gt;                backStr = reader.ReadLine();&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;  17:  &lt;/span&gt;                reader.Close();&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;  18:  &lt;/span&gt;            }&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;  19:  &lt;/span&gt;        }&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;  20:  &lt;/span&gt;        &lt;span class="kwrd"&gt;catch&lt;/span&gt; (IsolatedStorageException)&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;  21:  &lt;/span&gt;        {&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;  22:  &lt;/span&gt;            ;&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;  23:  &lt;/span&gt;        }&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;  24:  &lt;/span&gt;    }&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;  25:  &lt;/span&gt;&amp;#160;&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;  26:  &lt;/span&gt;    f = ToColor(foreStr);&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;  27:  &lt;/span&gt;    b = ToColor(backStr);&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;  28:  &lt;/span&gt;}&lt;/pre&gt;
&lt;/div&gt;
&lt;style type="text/css"&gt;






























.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }&lt;/style&gt;

&lt;p&gt;Let’s take a line-by-line look:&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;&lt;strong&gt;3-4: &lt;/strong&gt;Initialize two color strings to a default, should something go wrong.&lt;/p&gt;

  &lt;p&gt;&lt;strong&gt;6-7:&lt;/strong&gt; Get the isolated storage associated with this user and this application (defined by the XAP file’s URL).&amp;#160; If I wanted to share preferences across a suite of applications on the same host, I could have used &lt;code&gt;GetUserStoreForSite&lt;/code&gt; here.&lt;/p&gt;

  &lt;p&gt;&lt;strong&gt;11:&lt;/strong&gt; Open a file with the name &lt;code&gt;colors.txt&lt;/code&gt; in the isolated storage.&amp;#160; If the file is not found, an exception will be thrown (and caught in Line 20).&amp;#160; There is also a method I could have used to check for file existence instead of letting the exception catch it.&lt;/p&gt;

  &lt;p&gt;&lt;strong&gt;14-17:&lt;/strong&gt; Use a stream reader to read the two lines of the file.&lt;/p&gt;

  &lt;p&gt;&lt;strong&gt;20:&lt;/strong&gt; Handle an access exception, including file-not-found.&amp;#160; Here, we&amp;#160; just let the default colors take over.&lt;/p&gt;

  &lt;p&gt;&lt;strong&gt;26-27:&lt;/strong&gt; Convert the hex strings to color objects using a simple utility routine (below).&lt;/p&gt;
&lt;/blockquote&gt;

&lt;blockquote&gt;
  &lt;pre class="csharpcode"&gt;&lt;span class="kwrd"&gt;private&lt;/span&gt; Color ToColor(&lt;span class="kwrd"&gt;string&lt;/span&gt; hex)
{
    &lt;span class="kwrd"&gt;if&lt;/span&gt; (hex == &lt;span class="kwrd"&gt;null&lt;/span&gt;) &lt;span class="kwrd"&gt;return&lt;/span&gt; Color.FromArgb(255, 0, 0, 0);

    &lt;span class="kwrd"&gt;return&lt;/span&gt; Color.FromArgb(
        (&lt;span class="kwrd"&gt;byte&lt;/span&gt;)(Convert.ToUInt32(hex.Substring(0, 2), 16)),
        (&lt;span class="kwrd"&gt;byte&lt;/span&gt;)(Convert.ToUInt32(hex.Substring(2, 2), 16)),
        (&lt;span class="kwrd"&gt;byte&lt;/span&gt;)(Convert.ToUInt32(hex.Substring(4, 2), 16)),
        (&lt;span class="kwrd"&gt;byte&lt;/span&gt;)(Convert.ToUInt32(hex.Substring(5, 2), 16)));
}&lt;/pre&gt;
  &lt;style type="text/css"&gt;





























.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }&lt;/style&gt;&lt;/blockquote&gt;

&lt;p&gt;&lt;font size="3"&gt;&lt;strong&gt;Writing to Isolated Storage&lt;/strong&gt;&lt;/font&gt;&lt;/p&gt;

&lt;p&gt;Now, for the other direction: writing modifications to the user preferences to isolated storage.&amp;#160; For that I’ve created another method, &lt;code&gt;SaveColors&lt;/code&gt;, which is called in each of the two button Click event handlers, after setting the new color to a randomly generated color.&amp;#160; The implementation of &lt;code&gt;SaveColors&lt;/code&gt; is as follows:&lt;/p&gt;

&lt;p&gt;&amp;#160;&lt;/p&gt;

&lt;div class="csharpcode"&gt;
  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;   1:  &lt;/span&gt;&lt;span class="kwrd"&gt;public&lt;/span&gt; &lt;span class="kwrd"&gt;void&lt;/span&gt; SaveColors(Brush fBrush, Brush bBrush)&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;   2:  &lt;/span&gt;{&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;   3:  &lt;/span&gt;    &lt;span class="kwrd"&gt;using&lt;/span&gt; (IsolatedStorageFile isf = &lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;   4:  &lt;/span&gt;           IsolatedStorageFile.GetUserStoreForApplication())&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;   5:  &lt;/span&gt;    {&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;   6:  &lt;/span&gt;            &lt;span class="kwrd"&gt;using&lt;/span&gt; (FileStream str = isf.OpenFile(&lt;span class="str"&gt;&amp;quot;colors.txt&amp;quot;&lt;/span&gt;, &lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;   7:  &lt;/span&gt;                   FileMode.OpenOrCreate, FileAccess.Write))&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;   8:  &lt;/span&gt;            {&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;   9:  &lt;/span&gt;                StreamWriter writer = &lt;span class="kwrd"&gt;new&lt;/span&gt; StreamWriter(str);&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;  10:  &lt;/span&gt;                writer.WriteLine(&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;  11:  &lt;/span&gt;                    FromColor(((SolidColorBrush) fBrush).Color));&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;  12:  &lt;/span&gt;                writer.WriteLine(&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;  13:  &lt;/span&gt;                    FromColor(((SolidColorBrush) bBrush).Color));&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;  14:  &lt;/span&gt;                writer.Close();&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;  15:  &lt;/span&gt;            }&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="lnum"&gt;  16:  &lt;/span&gt;    }&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="lnum"&gt;  17:  &lt;/span&gt;}&lt;/pre&gt;
&lt;/div&gt;
&lt;style type="text/css"&gt;





























.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }&lt;/style&gt;

&lt;blockquote&gt;
  &lt;p&gt;&lt;strong&gt;3-4:&lt;/strong&gt; Obtain the isolated storage for this user and application.&lt;/p&gt;

  &lt;p&gt;&lt;strong&gt;6-7:&lt;/strong&gt; Open (or create) the &lt;code&gt;colors.txt&lt;/code&gt; file for writing.&lt;/p&gt;

  &lt;p&gt;&lt;strong&gt;10-13:&lt;/strong&gt; Write the new color strings to the file.&amp;#160; &lt;code&gt;FromColor&lt;/code&gt; is another utility routine to convert a color to its hex string equivalent.&amp;#160; It’s implemented as a single line of code!&lt;/p&gt;

  &lt;pre class="csharpcode"&gt;&lt;span class="kwrd"&gt;private&lt;/span&gt; String FromColor(Color c)
{
    &lt;span class="kwrd"&gt;return&lt;/span&gt; String.Format(
        &lt;span class="str"&gt;&amp;quot;{0:x2}{1:x2}{2:x2}{3:x2}&amp;quot;&lt;/span&gt;, 
        c.A, c.R, c.G, c.B);
}&lt;/pre&gt;
  &lt;style type="text/css"&gt;





























.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }&lt;/style&gt;&lt;/blockquote&gt;

&lt;p&gt;&lt;font size="3"&gt;&lt;strong&gt;Managing Isolated Storage Limits&lt;/strong&gt;&lt;/font&gt;&lt;/p&gt;
&lt;a name="quota"&gt;&amp;#160;&lt;/a&gt; 

&lt;p&gt;The &lt;code&gt;IsolatedStorageFile&lt;/code&gt; class has two properties to return the size of the store (&lt;code&gt;Quota&lt;/code&gt;) as well as the available free space (&lt;code&gt;AvailableFreeSpace&lt;/code&gt;).&amp;#160; With that information you can test whether or not there’s sufficient space for whatever you’re planning to store next.&lt;/p&gt;

&lt;p&gt;If there isn’t, you can call the &lt;code&gt;IncreaseQuotaTo&lt;/code&gt; method to extend the amount of isolated storage space.&amp;#160; There are a few caveats when using this method to be aware of&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;You can only call this method in response to a user action, like a button Click event; otherwise, as a security precaution, it’s ignored. &lt;/li&gt;
&lt;/ul&gt;

&lt;ul&gt;
  &lt;li&gt;You can’t decrease the quota (without removing the store and recreating it). &lt;/li&gt;
&lt;/ul&gt;

&lt;ul&gt;
  &lt;li&gt;You will get an exception if you try to increase the quota to a value smaller than the current size; therefore, use the &lt;code&gt;Quota&lt;/code&gt; and &lt;code&gt;AvailableFreeSpace&lt;/code&gt; properties to check before you ask! &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Presuming the request is a valid one, the end user will be presented a dialog like the following:&lt;/p&gt;

&lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/IisforImplicit_14018/image_6.png"&gt;&lt;img style="border-right-width: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto" title="image" border="0" alt="image" src="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/IisforImplicit_14018/image_thumb_2.png" width="444" height="209" /&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;The boolean return value of &lt;code&gt;IncreaseQuotaTo&lt;/code&gt; is determined by the user’s response to this dialog.&lt;/p&gt;

&lt;p&gt;You can also see how much isolated storage Silverlight has associated with the current user – across ALL of the Silverllight applications he or she has browsed – by viewing the Application Storage tab on the Silverlight Configuration dialog.&amp;#160; You can get to this dialog by right-clicking on any web page currently hosting Silverlight content and selecting the Silverlight Configuration option from the context menu.&lt;/p&gt;

&lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/IisforImplicit_14018/image_8.png"&gt;&lt;img style="border-right-width: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto" title="image" border="0" alt="image" src="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/IisforImplicit_14018/image_thumb_3.png" width="348" height="275" /&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A couple of closing thoughts:&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;1.&amp;#160; &lt;a href="http://msdn.microsoft.com/en-us/library/system.io.isolatedstorage.isolatedstoragefile_members(VS.95).aspx"&gt;&lt;code&gt;IsolatedStorageFile&lt;/code&gt;&lt;/a&gt; has a number of other methods to allow you to create, remove, and check for the existence of files and directories within the store.&lt;/p&gt;

  &lt;p&gt;2.&amp;#160; The &lt;code&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/system.io.isolatedstorage.isolatedstoragesettings(VS.95).aspx"&gt;IsolatedStorageSettings&lt;/a&gt;&lt;/code&gt; class is a convenient way to store simple key-value pairs in isolated storage.&amp;#160; For the example above, it would have been a very appropriate option (but less interesting to discuss!)&lt;/p&gt;

  &lt;p&gt;2.&amp;#160; You can figure out where the actual file store is by setting a breakpoint in your code after the &lt;code&gt;IsolatedStorageFile&lt;/code&gt; reference has been obtained.&amp;#160; Look at the value of the &lt;code&gt;RootDirectory&lt;/code&gt; property.&amp;#160; &lt;br /&gt;

    &lt;br /&gt;When I was running the sample above, here’s what mine was set to:&lt;/p&gt;

  &lt;p&gt;&lt;code&gt;C:\Users\joneil\AppData\LocalLow\Microsoft\Silverlight\is 
      &lt;br /&gt;\23zwbqug.imk\r3q1ieeo.odx\1\s\f2jzlyu1vrz2g5zcgk0moakn1 

      &lt;br /&gt;pdsiwrcpx22ardrblfykpxui4aaahba\f&lt;/code&gt;&lt;/p&gt;&lt;/blockquote&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9453307" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/jimoneil/archive/tags/Silverlight/default.aspx">Silverlight</category><category domain="http://blogs.msdn.com/jimoneil/archive/tags/A-to-Z/default.aspx">A-to-Z</category></item><item><title>Prism 2: Now With Silverlight</title><link>http://blogs.msdn.com/jimoneil/archive/2009/02/18/prism-2-now-with-silverlight.aspx</link><pubDate>Thu, 19 Feb 2009 00:11:01 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9432509</guid><dc:creator>joneil</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/jimoneil/comments/9432509.aspx</comments><wfw:commentRss>http://blogs.msdn.com/jimoneil/commentrss.aspx?PostID=9432509</wfw:commentRss><description>&lt;p&gt;&lt;img style="border-right-width: 0px; margin: 0px 0px 10px 15px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="image" border="0" alt="image" align="right" src="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/Prism2NowWithSilverlight_E38E/image_3.png" width="155" height="240" /&gt; Back in the fall on our &lt;a href="http://blogs.msdn.com/jimoneil/archive/2008/09/02/northeast-roadshow.aspx"&gt;Northeast Roadshow&lt;/a&gt;, I presented on the various User &lt;strike&gt;Interface&lt;/strike&gt; Experience options available for both smart client and browser-based applications.&amp;#160; At the end of the discussion, I mentioned the &lt;a href="http://msdn.microsoft.com/en-us/library/dd458807.aspx"&gt;Composite Application Guidance for WPF&lt;/a&gt; (also known by its code name of Prism).&amp;#160; That body of work, the product of &lt;a href="http://msdn.microsoft.com/en-us/practices/default.aspx"&gt;Microsoft’s patterns &amp;amp; practices team&lt;/a&gt;, was focused on helping you build enterprise-level, &lt;em&gt;composite&lt;/em&gt; client applications, namely focusing on building loosely-coupled, pluggable components that can work together in the overall application.&lt;/p&gt;  &lt;p&gt;While many of the ideas and techniques espoused by that guidance transcend WPF itself, there was obviously a “hole” in that Silverlight was not specifically addressed.&amp;#160; At the time of my presentation, I mentioned a Silverlight version was ‘in the works’, and today the &lt;a href="http://msdn.microsoft.com/en-us/library/dd458809.aspx"&gt;Composite Application Guidance for WPF and Silverlight 2.0&lt;/a&gt; was announced:&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;offering insight on building modular and composite Silverlight applications, &lt;/li&gt;    &lt;li&gt;simplifying the composition of the user interface, and &lt;/li&gt;    &lt;li&gt;providing guidance and light tooling on &lt;strong&gt;reusing code between Silverlight and WPF&lt;/strong&gt;. &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;I’ve bolded part of the last point because it’s the most compelling piece of this to me.&amp;#160; It’s the first official recommendation I’ve seen for the oft-asked question of best practices for delivering WPF and Silverlight experiences from a common code-base.&amp;#160; I'm hoping it will help ease some of that “analysis paralysis” that we all have when trying to best leverage a new technology (or in this case TWO new techologies!).&lt;/p&gt;  &lt;p&gt;“In the box” (so to speak), you’ll find the following.&amp;#160; Enjoy!&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;Composite Application Library, &lt;/li&gt;    &lt;li&gt;Reference Implementation (Stock Traders application in WPF and Silverlight), &lt;/li&gt;    &lt;li&gt;Quick starts (9), &lt;/li&gt;    &lt;li&gt;How-Tos (26), and&lt;/li&gt;    &lt;li&gt;Lots of documentation for everything you want to know about UI patterns and client architectures. &lt;/li&gt; &lt;/ul&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9432509" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/jimoneil/archive/tags/Silverlight/default.aspx">Silverlight</category><category domain="http://blogs.msdn.com/jimoneil/archive/tags/WPF/default.aspx">WPF</category></item><item><title>Are You Game to Win $5000?</title><link>http://blogs.msdn.com/jimoneil/archive/2009/02/12/are-you-game-to-win-5000.aspx</link><pubDate>Thu, 12 Feb 2009 20:06:43 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9415172</guid><dc:creator>joneil</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/jimoneil/comments/9415172.aspx</comments><wfw:commentRss>http://blogs.msdn.com/jimoneil/commentrss.aspx?PostID=9415172</wfw:commentRss><description>&lt;p&gt;&lt;a href="http://www.serverquestcontest.com"&gt;&lt;img style="border-bottom: 0px; border-left: 0px; display: block; float: none; margin-left: auto; border-top: 0px; margin-right: auto; border-right: 0px" title="ServerQuest II Contest" border="0" alt="ServerQuest II Contest" src="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/AreYouGametoWin5000_AA34/clip_image002_3.jpg" width="505" height="123" /&gt;&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;Check out this &lt;a href="http://www.serverquestcontest.com/index.aspx"&gt;new Silverlight developer competition&lt;/a&gt; in which you could pocket $5000 for showcasing your Silverlight skills.&amp;#160; The contest rules aren’t that apparent from the site unless you register (or spot the tiny link in the footer), so I’m copying below what you’ll see on the Submit Game page, post-registration.&amp;#160; The contest ends April 30th, with winners to be announced on May 25th.&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/AreYouGametoWin5000_AA34/320px-Left_pointing_double_angle_quotation_mark_sh1_svg_2.png"&gt;&lt;img style="border-right-width: 0px; margin: 0px 10px 0px 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="320px-Left_pointing_double_angle_quotation_mark_sh1_svg" border="0" alt="320px-Left_pointing_double_angle_quotation_mark_sh1_svg" align="left" src="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/AreYouGametoWin5000_AA34/320px-Left_pointing_double_angle_quotation_mark_sh1_svg_thumb.png" width="40" height="43" /&gt;&lt;/a&gt; It’s time to submit your finished game to Microsoft. When your game is placed in the gallery, everyone will have a chance to vote on it. The games with the highest amount of votes will be presented to a panel of Celebrity Geek Judges so they can vote on the best game. The winner’s game will be featured in Server Quest 2 and they will receive $5000.&lt;/p&gt;    &lt;p&gt;When submitting an entry to the Server Quest 2 Silverlight contest, you must supply an archive (zip file) containing:&lt;/p&gt;    &lt;ul&gt;     &lt;li&gt;The main game XAP file named game.xap in the top level of the archive. &lt;/li&gt;      &lt;li&gt;Your game should be formatted to fit a field of 800 px by 430 px. &lt;/li&gt;   &lt;/ul&gt;    &lt;p&gt;In addition, you must supply a screenshot of your game, it must be in JPG format and should be sized for 200 px by 150 px.&lt;/p&gt;    &lt;p&gt;The contest and its organizers are not responsible for games that are disqualified because of submissions which are of the wrong size, format, or file structure.&lt;a href="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/AreYouGametoWin5000_AA34/320px-Right_pointing_double_angle_quotation_mark_sh1_svg_2.png"&gt;&lt;img style="border-right-width: 0px; margin: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="320px-Right_pointing_double_angle_quotation_mark_sh1_svg" border="0" alt="320px-Right_pointing_double_angle_quotation_mark_sh1_svg" align="right" src="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/AreYouGametoWin5000_AA34/320px-Right_pointing_double_angle_quotation_mark_sh1_svg_thumb.png" width="38" height="41" /&gt;&lt;/a&gt;&lt;/p&gt;    &lt;p&gt;For a full list of rules and regulations, click &lt;a href="http://www.serverquestcontest.com/rules.aspx"&gt;here&lt;/a&gt;.&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;If you need a little help “getting your game on”, &lt;a href="http://www.andybeaulieu.com/Home/tabid/67/EntryID/120/Default.aspx"&gt;here’s a great post from Andy Beaulieu&lt;/a&gt; on some resources to get you started.&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9415172" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/jimoneil/archive/tags/Silverlight/default.aspx">Silverlight</category><category domain="http://blogs.msdn.com/jimoneil/archive/tags/Fun/default.aspx">Fun</category></item><item><title>Silverlight Control Mega-List</title><link>http://blogs.msdn.com/jimoneil/archive/2009/01/28/silverlight-control-mega-list.aspx</link><pubDate>Thu, 29 Jan 2009 03:01:22 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9382028</guid><dc:creator>joneil</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/jimoneil/comments/9382028.aspx</comments><wfw:commentRss>http://blogs.msdn.com/jimoneil/commentrss.aspx?PostID=9382028</wfw:commentRss><description>&lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/SilverlightControlMegaList_10B75/Silverlight%20h%20c%20reverse_2.png"&gt;&lt;img style="border-right-width: 0px; margin: 0px 20px 20px 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="Silverlight h c reverse" border="0" alt="Silverlight h c reverse" align="left" src="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/SilverlightControlMegaList_10B75/Silverlight%20h%20c%20reverse_thumb.png" width="240" height="78" /&gt;&lt;/a&gt;If you’re working on or considering Silverlight for application development, then the &lt;em&gt;sine quibus non&lt;/em&gt; of your daily blog reading should include both &lt;a href="http://timheuer.com/blog"&gt;Tim Heuer&lt;/a&gt; and &lt;a href="http://silverlight.net/blogs/jesseliberty/"&gt;Jesse Liberty&lt;/a&gt;.&lt;/p&gt;  &lt;p&gt;Tim just posted &lt;a href="http://timheuer.com/blog/archive/2009/01/28/comprehensive-list-of-silverlight-controls.aspx"&gt;A Comprehensive List of Silverlight Controls for Developers&lt;/a&gt;, an awesome reference post definitely worth filing away, check it out! &lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9382028" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/jimoneil/archive/tags/Silverlight/default.aspx">Silverlight</category></item><item><title>I Hereby Resolve To ...</title><link>http://blogs.msdn.com/jimoneil/archive/2008/12/26/i-hereby-resolve-to.aspx</link><pubDate>Sat, 27 Dec 2008 05:23:30 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9254052</guid><dc:creator>joneil</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/jimoneil/comments/9254052.aspx</comments><wfw:commentRss>http://blogs.msdn.com/jimoneil/commentrss.aspx?PostID=9254052</wfw:commentRss><description>&lt;p&gt;Having trouble figuring out how to fill in the blanks?&amp;nbsp; Fret no longer; I found this link to a &lt;a href="http://resolutionrandomizer.pop.us/ecard.aspx"&gt;Resolution Randomizer&lt;/a&gt; on &lt;a href="http://blogs.msdn.com/brada"&gt;Brad Abrams's&lt;/a&gt; blog, and it's too fun not to forward on.&amp;nbsp; Plus it's a Silverlight application and, therefore, legitimately work-related!&lt;/p&gt; &lt;p align="center"&gt;&lt;a href="http://resolutionrandomizer.pop.us/ecard.aspx"&gt;&lt;img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="326" alt="Resoution Randomizer" src="http://blogs.msdn.com/blogfiles/jimoneil/WindowsLiveWriter/IHerebyResolveTo_12CBE/image_3.png" width="389" border="0"&gt;&lt;/a&gt;&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9254052" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/jimoneil/archive/tags/Silverlight/default.aspx">Silverlight</category></item></channel></rss>