<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://beta.blogs.microsoft.co.il/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>Janiv Ratson&amp;#39;s Blog : WPF</title><link>http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/WPF/default.aspx</link><description>Tags: WPF</description><dc:language>en</dc:language><generator>CommunityServer 2007.1 (Build: 20917.1142)</generator><item><title>The Easiest Way to Add a Splash Screen to Your WPF Application</title><link>http://beta.blogs.microsoft.co.il/blogs/janiv/archive/2010/05/23/the-easiest-way-to-add-a-splash-screen-to-your-wpf-application.aspx</link><pubDate>Mon, 24 May 2010 03:31:06 GMT</pubDate><guid isPermaLink="false">b5c4f5bc-c09b-4439-a595-91a98c1847df:636480</guid><dc:creator>Janiv Ratson</dc:creator><slash:comments>4</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://beta.blogs.microsoft.co.il/blogs/janiv/rsscomments.aspx?PostID=636480</wfw:commentRss><comments>http://beta.blogs.microsoft.co.il/blogs/janiv/archive/2010/05/23/the-easiest-way-to-add-a-splash-screen-to-your-wpf-application.aspx#comments</comments><description>&lt;p&gt;It has been a long time …&lt;/p&gt;  &lt;p&gt;WPF applications do not start immediately. When an application is being loaded, there’s a delay while the CLR initializes the .NET environment and then starts the application.    &lt;br /&gt;Splash screens are typically used to notify the user that the application is in the process of loading.&lt;/p&gt;  &lt;p&gt;The easiest way to add a splash screen to your WPF application is to have Visual Studio 2008 SP1 or later and to follow these steps:&lt;/p&gt;  &lt;p&gt;1. Add an image file to your project. (you can use the BMP, GIF, JPEG, PNG or TIFF format)&amp;#160; .    &lt;br /&gt;2. Select the file in the Solution Explorer.&amp;#160; &lt;br /&gt;3. Change the Build Action to &lt;strong&gt;SplashScreen&lt;/strong&gt;.&lt;/p&gt;  &lt;p&gt;The next time you run the application, the image will be shown immediately. Once the runtime environment is ready, and after the Application_Startup method has finished, your application’s first window appears, and the splash screen fades away within 300 milliseconds.&lt;/p&gt;  &lt;p&gt;To remove the splash screen from your application you may either set the image’s Build Action to None or exclude the image from your project.&lt;/p&gt;  &lt;p&gt;If you want to change the default fadeout duration (300 milliseconds), you’d have to take control over the SplashScreen.&lt;/p&gt;  &lt;p&gt;First of all, locate the Main method within your App.g.cs file. Assuming you have followed the easy steps mentioned above to add the splash screen, your code will look something like this:&lt;/p&gt;  &lt;div style="border-bottom:silver 1px solid;text-align:left;border-left:silver 1px solid;padding-bottom:4px;line-height:12pt;background-color:#f4f4f4;margin:20px 0px 10px;padding-left:4px;width:97.5%;padding-right:4px;font-family:&amp;#39;Courier New&amp;#39;, courier, monospace;direction:ltr;max-height:200px;font-size:8pt;overflow:auto;border-top:silver 1px solid;cursor:text;border-right:silver 1px solid;padding-top:4px;" 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:&amp;#39;Courier New&amp;#39;, 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:&amp;#39;Courier New&amp;#39;, 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:#008000;"&gt;/// &amp;lt;summary&amp;gt;&lt;/span&gt;&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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:#008000;"&gt;/// Application Entry Point.&lt;/span&gt;&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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:#008000;"&gt;/// &amp;lt;/summary&amp;gt;&lt;/span&gt;&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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; [System.STAThreadAttribute()]&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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; [System.Diagnostics.DebuggerNonUserCodeAttribute()]&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;static&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;void&lt;/span&gt; Main() &lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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;/pre&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:&amp;#39;Courier New&amp;#39;, 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;     SplashScreen splashScreen = &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; SplashScreen(&lt;span style="color:#006080;"&gt;&amp;quot;mySplashScreenImg.jpg&amp;quot;&lt;/span&gt;);&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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;     splashScreen.Show(&lt;span style="color:#0000ff;"&gt;true&lt;/span&gt;);&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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;     TestSplash.App app = &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; TestSplash.App();&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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;     app.InitializeComponent();&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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;     app.Run();&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;The &lt;em&gt;Show(true)&lt;/em&gt; call displays the splash screen image. The &lt;em&gt;true&lt;/em&gt; parameter tells the application to close the splash screen automatically.&lt;/p&gt;

&lt;p&gt;Modify the code to include the following:&lt;/p&gt;

&lt;div style="border-bottom:silver 1px solid;text-align:left;border-left:silver 1px solid;padding-bottom:4px;line-height:12pt;background-color:#f4f4f4;margin:20px 0px 10px;padding-left:4px;width:97.5%;padding-right:4px;font-family:&amp;#39;Courier New&amp;#39;, courier, monospace;direction:ltr;max-height:200px;font-size:8pt;overflow:auto;border-top:silver 1px solid;cursor:text;border-right:silver 1px solid;padding-top:4px;" 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:&amp;#39;Courier New&amp;#39;, 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:&amp;#39;Courier New&amp;#39;, 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:#008000;"&gt;/// &amp;lt;summary&amp;gt;&lt;/span&gt;&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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:#008000;"&gt;/// Application Entry Point.&lt;/span&gt;&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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:#008000;"&gt;/// &amp;lt;/summary&amp;gt;&lt;/span&gt;&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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; [System.STAThreadAttribute()]&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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; [System.Diagnostics.DebuggerNonUserCodeAttribute()]&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;static&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;void&lt;/span&gt; Main() &lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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;/pre&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:&amp;#39;Courier New&amp;#39;, 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;     SplashScreen splashScreen = &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; SplashScreen(&lt;span style="color:#006080;"&gt;&amp;quot;mySplashScreenImg.jpg&amp;quot;&lt;/span&gt;);&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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;     splashScreen.Show(&lt;span style="color:#0000ff;"&gt;false&lt;/span&gt;); &lt;span style="color:#008000;"&gt;//false to close the splash screen manually&lt;/span&gt;&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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;     TestSplash.App app = &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; TestSplash.App();&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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;     app.InitializeComponent();&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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;     splashScreen.Close(TimeSpan.FromMilliseconds(5000)); &lt;span style="color:#008000;"&gt;//five seconds fade out !&lt;/span&gt;&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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;     app.Run();&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;Now the splash screen’s fade out animation will take 5 seconds.&lt;/p&gt;&lt;img src="http://beta.blogs.microsoft.co.il/aggbug.aspx?PostID=636480" width="1" height="1"&gt;</description><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/WPF/default.aspx">WPF</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/Visual+Studio+2010/default.aspx">Visual Studio 2010</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/.NET+4.0/default.aspx">.NET 4.0</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/DEV/default.aspx">DEV</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/.NET/default.aspx">.NET</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/SplashScreen/default.aspx">SplashScreen</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/Splash+Screen/default.aspx">Splash Screen</category></item><item><title>Embedding and Communicating with the Macromedia Flash Player in WPF</title><link>http://beta.blogs.microsoft.co.il/blogs/janiv/archive/2009/09/20/embedding-and-communicating-with-the-macromedia-flash-player-in-wpf.aspx</link><pubDate>Sun, 20 Sep 2009 19:48:00 GMT</pubDate><guid isPermaLink="false">b5c4f5bc-c09b-4439-a595-91a98c1847df:409694</guid><dc:creator>Janiv Ratson</dc:creator><slash:comments>5</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://beta.blogs.microsoft.co.il/blogs/janiv/rsscomments.aspx?PostID=409694</wfw:commentRss><comments>http://beta.blogs.microsoft.co.il/blogs/janiv/archive/2009/09/20/embedding-and-communicating-with-the-macromedia-flash-player-in-wpf.aspx#comments</comments><description>&lt;blockquote&gt;&amp;nbsp;&lt;/blockquote&gt;
&lt;div style="PADDING-BOTTOM:0px;MARGIN:0px;PADDING-LEFT:0px;PADDING-RIGHT:0px;DISPLAY:inline;FLOAT:none;PADDING-TOP:0px;" id="scid:F60BB8FA-6F02-4999-8F5E-9DD4E92C4DA7:e4491857-5d97-4808-a761-2ea2dbe1c02f" class="wlWriterEditableSmartContent"&gt;
&lt;div&gt;&lt;a href="http://blogs.microsoft.co.il/blogs/janiv/MyBlogUserControls_13A8E0A6.zip" target="_blank"&gt;Download Source Code and Binaries (MyBlogUserControls.zip)&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;Embedding the &lt;a href="http://get.adobe.com/flashplayer/" target="_blank"&gt;Macromedia Flash Player&lt;/a&gt; ActiveX control is a relatively simple way to do the following:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Add functionality, graphics, or animation to your WPF application. &lt;/li&gt;
&lt;li&gt;Extend the capabilities of your stand-alone Macromedia Flash application (such as adding file I/O capabilities to Macromedia Flash). &lt;/li&gt;
&lt;li&gt;Use existing flash resources in your WPF application (i.e. Use Banners in your WPF application) &lt;/li&gt;&lt;/ul&gt;
&lt;p&gt;Before you decide to embed the Macromedia Flash Player ActiveX control within your WPF application, however, there are a number of things that you should consider:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Macromedia does not officially support embedding the Macromedia Flash Player ActiveX control within a Windows application. This means that future versions of the player may not work with your application. &lt;/li&gt;
&lt;li&gt;It requires users to install the Macromedia Flash Player ActiveX control on their computers. This can be done by installing the player within Microsoft Internet Explorer. Although it is technically possible to distribute the player, that is restricted by the player&amp;#39;s end-user license agreement. If you need to distribute the Macromedia Flash Player ActiveX control, &lt;a href="http://www.adobe.com/support/shockwave/info/licensing/" target="_blank"&gt;contact Macromedia for permission&lt;/a&gt;. &lt;/li&gt;
&lt;li&gt;Because it uses ActiveX technology, it works only on Windows OS. &lt;/li&gt;
&lt;li&gt;Versions of the Macromedia Flash Player prior to version 6 did not support embedding within Windows applications. Users need version 6.0r79 or higher. &lt;/li&gt;&lt;/ul&gt;
&lt;p&gt;The easiest way to use the Macromedia Flash Player ActiveX control within your WPF applications is to create a WPF user control that will wrap the Flash Player. &lt;br /&gt;As WPF currently does not support such a wrapper, we will use another wrapper of type WindowsFormsHost. &lt;br /&gt;We’ll learn how to display Flash Player media within WPF application by following 4 major steps.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;&lt;font size="3"&gt;Step 1. Creating a WPF User Control Library&lt;/font&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Our final goal would be having a WPF user control that would play Flash media files (swf/flv). Therefore, our first step is to create the WPF User Control Library that would wrap it all, and will be used by any WPF window or page.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;1.&lt;/strong&gt; Create a new WPF User Control Library project (mine was named &lt;em&gt;MyBlogUserControls&lt;/em&gt;) &lt;/p&gt;
&lt;p&gt;&lt;a href="http://blogs.microsoft.co.il/blogs/janiv/CreateTheWPFProject_3312C37F.png"&gt;&lt;img style="BORDER-RIGHT-WIDTH:0px;DISPLAY:inline;BORDER-TOP-WIDTH:0px;BORDER-BOTTOM-WIDTH:0px;BORDER-LEFT-WIDTH:0px;" title="CreateTheWPFProject" border="0" alt="CreateTheWPFProject" src="http://blogs.microsoft.co.il/blogs/janiv/CreateTheWPFProject_thumb_1795738F.png" width="687" height="442" /&gt;&lt;/a&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;2.&lt;/strong&gt; Add a new WPF User Control&lt;/p&gt;
&lt;p&gt;&lt;a href="http://blogs.microsoft.co.il/blogs/janiv/AddWPFUserControl_15168495.png"&gt;&lt;img style="BORDER-RIGHT-WIDTH:0px;DISPLAY:inline;BORDER-TOP-WIDTH:0px;BORDER-BOTTOM-WIDTH:0px;BORDER-LEFT-WIDTH:0px;" title="AddWPFUserControl" border="0" alt="AddWPFUserControl" src="http://blogs.microsoft.co.il/blogs/janiv/AddWPFUserControl_thumb_44F8D869.png" width="698" height="426" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;3.&lt;/strong&gt; Add a Uri property and a Loaded event to your new WPF User Control&lt;/p&gt;&lt;pre class="csharpcode"&gt;&lt;span class="kwrd"&gt;&lt;font color="#000000"&gt;&lt;span class="kwrd"&gt;public&lt;/span&gt; Uri Source { get; set; }     

&lt;span class="kwrd"&gt;private&lt;/span&gt; &lt;span class="kwrd"&gt;void&lt;/span&gt; FlashPlayer_Loaded(&lt;span class="kwrd"&gt;object&lt;/span&gt; sender, RoutedEventArgs e)
{&lt;/font&gt;&lt;/span&gt;&lt;/pre&gt;&lt;pre class="csharpcode"&gt;&lt;span class="kwrd"&gt;&lt;font color="#000000"&gt;
}&lt;/font&gt;&lt;/span&gt;&lt;/pre&gt;&lt;pre class="csharpcode"&gt;&lt;span class="kwrd"&gt;&lt;/span&gt;&lt;strong&gt;&lt;font size="3"&gt;Step 2. Creating a Windows Forms User Control&lt;/font&gt;&lt;/strong&gt;&lt;/pre&gt;
&lt;p&gt;As WPF does not support hosting an ActiveX control directly but Windows Forms does, we will use the &lt;a href="http://msdn.microsoft.com/en-us/cc527394.aspx" target="_blank"&gt;Crossbow technology&lt;/a&gt; to host the Flash Player within our WPF application. We will add the Macromedia Flash Player ActiveX Control to our toolbox, and will wrap it within a Windows Forms User Control.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;1.&lt;/strong&gt; In your new project, add a reference to the &lt;a href="http://msdn.microsoft.com/en-us/library/system.windows.forms.integration.aspx" target="_blank"&gt;WindowsFormsIntegration namespace&lt;/a&gt; (from the .NET tab)&lt;/p&gt;
&lt;p&gt;&lt;a href="http://blogs.microsoft.co.il/blogs/janiv/AddWindowsFormsIntegrationRef_303122AD.png"&gt;&lt;img style="BORDER-RIGHT-WIDTH:0px;DISPLAY:inline;BORDER-TOP-WIDTH:0px;BORDER-BOTTOM-WIDTH:0px;BORDER-LEFT-WIDTH:0px;" title="AddWindowsFormsIntegrationRef" border="0" alt="AddWindowsFormsIntegrationRef" src="http://blogs.microsoft.co.il/blogs/janiv/AddWindowsFormsIntegrationRef_thumb_2B097802.png" width="709" height="368" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;2.&lt;/strong&gt; Add a new Windows Forms User Control to your project&lt;/p&gt;
&lt;p&gt;&lt;a href="http://blogs.microsoft.co.il/blogs/janiv/AddWinFormsUserControl_795B2E21.png"&gt;&lt;img style="BORDER-RIGHT-WIDTH:0px;DISPLAY:inline;BORDER-TOP-WIDTH:0px;BORDER-BOTTOM-WIDTH:0px;BORDER-LEFT-WIDTH:0px;" title="AddWinFormsUserControl" border="0" alt="AddWinFormsUserControl" src="http://blogs.microsoft.co.il/blogs/janiv/AddWinFormsUserControl_thumb_2BE63DA7.png" width="714" height="433" /&gt;&lt;/a&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;3.&lt;/strong&gt; Open the new Windows Form User Control in design mode, and make sure the Toolbox toolbar is visible.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;4.&lt;/strong&gt; Right Click the toolbar within the All Windows Forms tab of the Toolbox toolbar and select the “Choose Items…” menu option. &lt;/p&gt;
&lt;p&gt;&lt;a href="http://blogs.microsoft.co.il/blogs/janiv/ToolboxContextMenu_68C5023D.png"&gt;&lt;img style="BORDER-RIGHT-WIDTH:0px;DISPLAY:inline;BORDER-TOP-WIDTH:0px;BORDER-BOTTOM-WIDTH:0px;BORDER-LEFT-WIDTH:0px;" title="ToolboxContextMenu" border="0" alt="ToolboxContextMenu" src="http://blogs.microsoft.co.il/blogs/janiv/ToolboxContextMenu_thumb_7DDB3005.png" width="407" height="621" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;5.&lt;/strong&gt; The Choose Toolbox Items dialog is opened. Go to COM Components tab, scroll down to the Shockwave Flash Object item and check it. Press OK. &lt;br /&gt;If this item is not listed, make sure that the Macromedia Flash Player ActiveX control is installed on your system.&lt;/p&gt;
&lt;p&gt;&lt;a href="http://blogs.microsoft.co.il/blogs/janiv/ChooseToolboxItems_28712DDA.png"&gt;&lt;img style="BORDER-RIGHT-WIDTH:0px;DISPLAY:inline;BORDER-TOP-WIDTH:0px;BORDER-BOTTOM-WIDTH:0px;BORDER-LEFT-WIDTH:0px;" title="ChooseToolboxItems" border="0" alt="ChooseToolboxItems" src="http://blogs.microsoft.co.il/blogs/janiv/ChooseToolboxItems_thumb_17B656A1.png" width="653" height="453" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;6.&lt;/strong&gt; Now you should have a Shockwave Flash Object within the All Windows Forms tab of the Toolbox toolbar&lt;/p&gt;
&lt;p&gt;&lt;a href="http://blogs.microsoft.co.il/blogs/janiv/ShowaveInToolbox_4CA00986.png"&gt;&lt;img style="BORDER-RIGHT-WIDTH:0px;DISPLAY:inline;BORDER-TOP-WIDTH:0px;BORDER-BOTTOM-WIDTH:0px;BORDER-LEFT-WIDTH:0px;" title="ShowaveInToolbox" border="0" alt="ShowaveInToolbox" src="http://blogs.microsoft.co.il/blogs/janiv/ShowaveInToolbox_thumb_6698EB0A.png" width="376" height="576" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;7.&lt;/strong&gt; Add the flash object to your Windows Forms User Control by dragging it, set its size according to your needs (if size is static), and name it (i.e. axShockwaveFlash).&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;8.&lt;/strong&gt; Go to the Windows Form User Control source code and add Flash Player methods&lt;/p&gt;&lt;pre class="csharpcode"&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; WFFlashPlayer : UserControl
{
        &lt;span class="kwrd"&gt;public&lt;/span&gt; WFFlashPlayer()
        {
            InitializeComponent();
        }

        &lt;span class="kwrd"&gt;public&lt;/span&gt; &lt;span class="kwrd"&gt;new&lt;/span&gt; &lt;span class="kwrd"&gt;int&lt;/span&gt; Width 
        {
            get{ &lt;span class="kwrd"&gt;return&lt;/span&gt; axShockwaveFlash.Width; }
            set{ axShockwaveFlash.Width = &lt;span class="kwrd"&gt;value&lt;/span&gt;; }
        }

        &lt;span class="kwrd"&gt;public&lt;/span&gt; &lt;span class="kwrd"&gt;new&lt;/span&gt; &lt;span class="kwrd"&gt;int&lt;/span&gt; Height 
        {
            get{ &lt;span class="kwrd"&gt;return&lt;/span&gt; axShockwaveFlash.Height; }
            set{ axShockwaveFlash.Height = &lt;span class="kwrd"&gt;value&lt;/span&gt;; }
        }

        &lt;span class="kwrd"&gt;public&lt;/span&gt; &lt;span class="kwrd"&gt;void&lt;/span&gt; LoadMovie(&lt;span class="kwrd"&gt;string&lt;/span&gt; strPath)
        {
            axShockwaveFlash.LoadMovie(0, strPath);            
        }
       
        &lt;span class="kwrd"&gt;public&lt;/span&gt; &lt;span class="kwrd"&gt;void&lt;/span&gt; Play()
        {            
            axShockwaveFlash.Play();
        }

        &lt;span class="kwrd"&gt;public&lt;/span&gt; &lt;span class="kwrd"&gt;void&lt;/span&gt; Stop()
        {
            axShockwaveFlash.Stop();
        }        
}&lt;/pre&gt;









.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, &amp;quot;Courier New&amp;quot;, 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; }










.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, &amp;quot;Courier New&amp;quot;, 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;p&gt;Once we’ve completed this step, we have a Windows Forms User Control that wraps a Flash Player. Now we need to make it a WPF user control.&lt;/p&gt;
&lt;p&gt;&lt;font size="3"&gt;&lt;strong&gt;Step 3. Wrapping the Windows Forms User Control within our new WPF User Control using Crossbow&lt;/strong&gt;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;1.&lt;/strong&gt; Open the WPF User Control XAML file.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;2.&lt;/strong&gt; Name the main Grid (or any other WPF container you’d like)&lt;/p&gt;&lt;pre class="csharpcode"&gt;&lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;UserControl&lt;/span&gt; &lt;span class="attr"&gt;x:Class&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;MyBlogUserControls.FlashPlayer&amp;quot;&lt;/span&gt;
    &lt;span class="attr"&gt;xmlns&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;http://schemas.microsoft.com/winfx/2006/xaml/presentation&amp;quot;&lt;/span&gt;
    &lt;span class="attr"&gt;xmlns:x&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;http://schemas.microsoft.com/winfx/2006/xaml&amp;quot;&lt;/span&gt;
    &lt;span class="attr"&gt;Height&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;300&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;Width&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;300&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;Loaded&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;FlashPlayer_Loaded&amp;quot;&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
    
    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Grid&lt;/span&gt; &lt;span class="attr"&gt;Name&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;FlashPlayerGrid&amp;quot;&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;            
    &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;Grid&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;UserControl&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;









.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, &amp;quot;Courier New&amp;quot;, 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;p&gt;&lt;strong&gt;3.&lt;/strong&gt; Open the WPF User Control Source Code.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;4.&lt;/strong&gt; Fill the Loaded event body with code to host the Windows Forms Flash Player, load the movie and play it&lt;/p&gt;&lt;pre class="csharpcode"&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; FlashPlayer : UserControl
{
        &lt;span class="kwrd"&gt;public&lt;/span&gt; FlashPlayer()
        {
            InitializeComponent();
        }

        &lt;span class="kwrd"&gt;public&lt;/span&gt; Uri Source { get; set; }     

        &lt;span class="kwrd"&gt;private&lt;/span&gt; &lt;span class="kwrd"&gt;void&lt;/span&gt; FlashPlayer_Loaded(&lt;span class="kwrd"&gt;object&lt;/span&gt; sender, RoutedEventArgs e)
        {
            WindowsFormsHost host = &lt;span class="kwrd"&gt;new&lt;/span&gt; WindowsFormsHost();
            WFFlashPlayer player = &lt;span class="kwrd"&gt;new&lt;/span&gt; WFFlashPlayer();
                        
            &lt;span class="rem"&gt;//the Windows Forms Host hosts the Flash Player&lt;/span&gt;
            host.Child = player;

            &lt;span class="rem"&gt;//the WPF Grid hosts the Windows Forms Host&lt;/span&gt;
            FlashPlayerGrid.Children.Add(host);

            &lt;span class="rem"&gt;//set size&lt;/span&gt;
            player.Width = (&lt;span class="kwrd"&gt;int&lt;/span&gt;)Width;
            player.Height = (&lt;span class="kwrd"&gt;int&lt;/span&gt;)Height;

            &lt;span class="rem"&gt;//load &amp;amp; play the movie&lt;/span&gt;
            player.LoadMovie(Source.AbsoluteUri);
            player.Play();
        }
}&lt;/pre&gt;
&lt;p&gt;&lt;font size="3"&gt;&lt;strong&gt;Step 4. Using the new WPF Flash Player Control&lt;/strong&gt;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;Let’s use our new Flash Player within a WPF application.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;1.&lt;/strong&gt; Create a new WPF Application.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;2.&lt;/strong&gt; Add a reference to your User Controls Library (mine was MyBlogUserControls)&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;3.&lt;/strong&gt; Open your Window’s XAML file.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;4.&lt;/strong&gt; Add the WPF User Control Library namespace to the Window Object&lt;/p&gt;&lt;pre class="csharpcode"&gt;&lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Window&lt;/span&gt; &lt;span class="attr"&gt;x:Class&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;WPFLibTester.FirstPage&amp;quot;&lt;/span&gt;
    &lt;span class="attr"&gt;xmlns&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;http://schemas.microsoft.com/winfx/2006/xaml/presentation&amp;quot;&lt;/span&gt;
    &lt;span class="attr"&gt;xmlns:x&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;http://schemas.microsoft.com/winfx/2006/xaml&amp;quot;&lt;/span&gt;
    &lt;span class="attr"&gt;xmlns:controls&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;clr-namespace:MyBlogUserControls;assembly=MyBlogUserControls&amp;quot;&lt;/span&gt;
    &lt;span class="attr"&gt;Title&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;FirstPage&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;Height&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;800&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;Width&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;800&amp;quot;&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;









.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, &amp;quot;Courier New&amp;quot;, 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;p&gt;&lt;strong&gt;5.&lt;/strong&gt; Add the WPF Flash Player to your window and set its source and size&lt;/p&gt;&lt;pre class="csharpcode"&gt;&lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Window&lt;/span&gt; &lt;span class="attr"&gt;x:Class&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;WPFLibTester.FirstPage&amp;quot;&lt;/span&gt;
    &lt;span class="attr"&gt;xmlns&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;http://schemas.microsoft.com/winfx/2006/xaml/presentation&amp;quot;&lt;/span&gt;
    &lt;span class="attr"&gt;xmlns:x&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;http://schemas.microsoft.com/winfx/2006/xaml&amp;quot;&lt;/span&gt;
    &lt;span class="attr"&gt;xmlns:controls&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;clr-namespace:MyBlogUserControls;assembly=MyBlogUserControls&amp;quot;&lt;/span&gt;
    &lt;span class="attr"&gt;Title&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;FirstPage&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;Height&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;800&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;Width&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;800&amp;quot;&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Grid&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;        
        &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;controls:FlashPlayer&lt;/span&gt; &lt;span class="attr"&gt;Source&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;http://www.sothink.com/product/swfquicker/samples/specialEffect/Art_studio.swf&amp;quot;&lt;/span&gt; 
                  &lt;span class="attr"&gt;Width&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;700&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;Height&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;600&amp;quot;&lt;/span&gt; &lt;span class="kwrd"&gt;&amp;gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;controls:FlashPlayer&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;Grid&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;Window&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;&lt;pre class="csharpcode"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;p&gt;That’s it. I’ve covered here three methods from the Shockwave Flash Media Object. Of course you can communicate with any of the Flash Object API methods, by calling them from your Windows Forms User Control wrapper. &lt;/p&gt;
&lt;p&gt;If you have troubles setting your Adobe Flash Player, you may find help &lt;a href="http://blogs.microsoft.co.il/controlpanel/blogs/Troubleshoot%20Adobe%20Flash%20Player%20installation%20for%20Windows" target="_blank"&gt;here&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Enjoy.&lt;/p&gt;&lt;img src="http://beta.blogs.microsoft.co.il/aggbug.aspx?PostID=409694" width="1" height="1"&gt;</description><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/WPF/default.aspx">WPF</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/DEV/default.aspx">DEV</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/.NET/default.aspx">.NET</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/Macromedia+Shockwave/default.aspx">Macromedia Shockwave</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/Banner/default.aspx">Banner</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/SWF/default.aspx">SWF</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/Windows+Forms/default.aspx">Windows Forms</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/Flash/default.aspx">Flash</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/FLV/default.aspx">FLV</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/Crossbow/default.aspx">Crossbow</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/Adobe+Flash+Player/default.aspx">Adobe Flash Player</category></item><item><title>Prototyping a WPF-3D game design workflow using TrueSpace 3D, Expression Blend 3 with SketchFlow</title><link>http://beta.blogs.microsoft.co.il/blogs/janiv/archive/2009/08/02/prototyping-a-wpf-3d-game-design-workflow-using-truespace-3d-expression-blend-3-with-sketchflow.aspx</link><pubDate>Sun, 02 Aug 2009 11:52:00 GMT</pubDate><guid isPermaLink="false">b5c4f5bc-c09b-4439-a595-91a98c1847df:373267</guid><dc:creator>Janiv Ratson</dc:creator><slash:comments>1</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://beta.blogs.microsoft.co.il/blogs/janiv/rsscomments.aspx?PostID=373267</wfw:commentRss><comments>http://beta.blogs.microsoft.co.il/blogs/janiv/archive/2009/08/02/prototyping-a-wpf-3d-game-design-workflow-using-truespace-3d-expression-blend-3-with-sketchflow.aspx#comments</comments><description>&lt;p&gt;Interesting article on SketchFlow by Don Burnett:&lt;br /&gt;&lt;a href="http://www.uxmagic.com/blog/post/2009/07/12/Prototyping-a-WPF-3D-game-design-workflow-using-TrueSpace-3D-Expression-Blend-3-with-Sketchflow-and-exporting-the-prototype-XNA-Game-Studio.aspx"&gt;http://www.uxmagic.com/blog/post/2009/07/12/Prototyping-a-WPF-3D-game-design-workflow-using-TrueSpace-3D-Expression-Blend-3-with-Sketchflow-and-exporting-the-prototype-XNA-Game-Studio.aspx&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Background&lt;/strong&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;quot;Expression Studio’s Blend 3 With SketchFlow is an amazing tool.&amp;nbsp;I have known about SketchFlow for a very long time (since March 2008. Microsoft had worked on gathering idea for it and spent a lot time on the concept, from customer feedback as early as 2006-2007 (maybe even before that). It has been in the works for a very long time with a huge amount of planning on the Expression team’s part. &lt;/p&gt;
&lt;p&gt;While it is not UML,&amp;nbsp;Sketchflow gives the same benefits and more. You can literally take a wireframe graphic to completed design all in the same tool. The player lets you share your work with your clients and fellow team members, let them mark up comments and make enhancements and changes and doesn’t require you to even be inside of blend. You could share it as a file (really a WPF based application)&amp;nbsp; or even on the web on a shared website using Silverlight.&amp;quot;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;img src="http://beta.blogs.microsoft.co.il/aggbug.aspx?PostID=373267" width="1" height="1"&gt;</description><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/WPF/default.aspx">WPF</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/DEV/default.aspx">DEV</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/Blend+3/default.aspx">Blend 3</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/Sketchflow/default.aspx">Sketchflow</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/TrueSpace/default.aspx">TrueSpace</category></item><item><title>WPF Localization Guidance</title><link>http://beta.blogs.microsoft.co.il/blogs/janiv/archive/2009/07/01/wpf-localization-guidance.aspx</link><pubDate>Wed, 01 Jul 2009 14:59:00 GMT</pubDate><guid isPermaLink="false">b5c4f5bc-c09b-4439-a595-91a98c1847df:352176</guid><dc:creator>Janiv Ratson</dc:creator><slash:comments>1</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://beta.blogs.microsoft.co.il/blogs/janiv/rsscomments.aspx?PostID=352176</wfw:commentRss><comments>http://beta.blogs.microsoft.co.il/blogs/janiv/archive/2009/07/01/wpf-localization-guidance.aspx#comments</comments><description>&lt;p&gt;When you limit your product&amp;#39;s availability to only one language, you limit your potential customer base to a fraction of our world’s &lt;a href="http://www96.wolframalpha.com/input/?i=world+population" target="_blank"&gt;&lt;font color="#0065e2"&gt;6.67 billion population&lt;/font&gt;&lt;/a&gt;. If you want your applications to reach a global audience, cost-effective localization of your product is one of the best and most economical ways to reach more customers. &lt;br /&gt;It is imperative to define a globalization strategy early in the development lifecycle, in order to more quickly accommodate demands for future product releases that can reach global markets.&lt;/p&gt;
&lt;p&gt;Application localization is not a trivial task for any type of application scenario. The process is based on a few core principles that apply to WPF as they do to any other type of client application with a user interface. &lt;br /&gt;It is important for developers to understand the basic concepts of regional data display, locale-specific user interface customization and how to serve localized resources in both static and dynamic fashion. These concepts are very similar for most client applications but the actual process of localizing the static user interface components tends to vary between environments and WPF introduces yet another approach to resource localization for XAML resources. &lt;/p&gt;
&lt;p&gt;&lt;a href="http://www.west-wind.com/Weblog/" target="_blank"&gt;&lt;font color="#0065e2"&gt;Rick Strahl&lt;/font&gt;&lt;/a&gt; &amp;amp; &lt;a href="http://msdn.microsoft.com/en-us/asp.net/aa336538.aspx" target="_blank"&gt;&lt;font color="#0065e2"&gt;Michele Leroux Bustamante&lt;/font&gt;&lt;/a&gt; have published a Localization Guidance whitepaper (June 2009). It starts with a quick review of general localization considerations for completeness, discusses how the .NET Framework handles resources for all applications, and then focuses specifically on localization scenarios for WPF explaining some of the trade-offs within each approach. &lt;br /&gt;This whitepaper is complete and may be updated according to YOUR feedbacks. &lt;br /&gt;Download it (and some source code) here: &lt;a href="http://wpflocalization.codeplex.com/Release/ProjectReleases.aspx?ReleaseId=29389" target="_blank"&gt;&lt;font color="#0065e2"&gt;WPF Localization Guidance Whitepaper&lt;/font&gt;&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;You may also be interested in Microsoft&amp;#39;s &lt;a href="http://msdn.microsoft.com/en-us/library/ms788718.aspx" target="_blank"&gt;&lt;font color="#0065e2"&gt;WPF Globalization and Localization Overview&lt;/font&gt;&lt;/a&gt;, which has a lot in common with RIck and Michele&amp;#39;s guidance. &lt;br /&gt;And how would you implement the the translation of application resources into localized versions for the specific cultures that the application supports? &lt;br /&gt;When you localize in WPF, you use the APIs in the &lt;a href="http://msdn.microsoft.com/en-us/library/system.windows.markup.localizer.aspx" target="_blank"&gt;&lt;font color="#0065e2"&gt;System.Windows.Markup.Localizer&lt;/font&gt;&lt;/a&gt; namespace. These APIs power the &lt;a href="http://msdn.microsoft.com/en-us/library/ms771568.aspx" target="_blank"&gt;&lt;font color="#0065e2"&gt;LocBaml Tool Sample&lt;/font&gt;&lt;/a&gt; command-line tool, which was developed by Microsoft to present a sample that uses some of the localization APIs and illustrates how you might write a localization tool. &lt;/p&gt;
&lt;p&gt;There is also the CodePlex &lt;a href="http://wpflocalizeextension.codeplex.com/" target="_blank"&gt;&lt;font color="#0065e2"&gt;WPF Localizationan Extention&lt;/font&gt;&lt;/a&gt; project which is a (FREE) stable extension project to localize any type of DependencyProperties on DependencyObjects.&lt;/p&gt;
&lt;p&gt;As you can see, there are many (and good) ways to implement localization in WPF project. If you know any other great localization tools, please share it with us. &lt;br /&gt;Thanks, &lt;br /&gt;J.&lt;/p&gt;&lt;img src="http://beta.blogs.microsoft.co.il/aggbug.aspx?PostID=352176" width="1" height="1"&gt;</description><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/WPF/default.aspx">WPF</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/DEV/default.aspx">DEV</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/Localization/default.aspx">Localization</category></item><item><title>Hardware Acceleration in WPF</title><link>http://beta.blogs.microsoft.co.il/blogs/janiv/archive/2009/06/07/hardware-acceleration-in-wpf.aspx</link><pubDate>Sun, 07 Jun 2009 06:46:18 GMT</pubDate><guid isPermaLink="false">b5c4f5bc-c09b-4439-a595-91a98c1847df:331748</guid><dc:creator>Janiv Ratson</dc:creator><slash:comments>8</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://beta.blogs.microsoft.co.il/blogs/janiv/rsscomments.aspx?PostID=331748</wfw:commentRss><comments>http://beta.blogs.microsoft.co.il/blogs/janiv/archive/2009/06/07/hardware-acceleration-in-wpf.aspx#comments</comments><description>&lt;p&gt;Recently I’ve been getting several questions on hardware acceleration. Some people are running performance profiling tools and noticing that although it indicates that their application is running in hardware, the application is still taxing the CPU. This may seem confusing, so I will try to give some background in this posting.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;&lt;font size="3"&gt;History&lt;/font&gt;&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;Windows developers have been using the same display technologies for more than 15 years. A standard Windows application relies on two well-worn parts of the Windows operating system to create its user interface:&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;User32 - provides the familiar Windows look and feel for elements such as windows, buttons, text boxes, and so on. &lt;/li&gt;    &lt;li&gt;GDI/GDI+ - provides drawing support for rendering shapes, text, and images at the cost of additional complexity (and often lackluster performance). &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;Over the years, both technologies have been refined, and the APIs that developers use to interact with them have changed dramatically. But behind the scenes the same parts of the Windows operating system are used. Newer frameworks simply deliver better interaction wrappers. &lt;/p&gt;  &lt;p&gt;WPF still relies on User32 for certain services, such as handling and routing input and sorting out which application owns which portion of screen real estate.&lt;/p&gt;  &lt;p&gt;&lt;font size="3"&gt;&lt;strong&gt;DirectX&lt;/strong&gt;&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;DirectX began as a cobbled-together, error-prone toolkit for creating games on the Windows platform. Its design mandate was speed, and so Microsoft worked closely with video card vendors to give DirectX the hardware acceleration needed for complex textures, special effects such as partial transparency, and three-dimensional graphics.    &lt;br /&gt;DirectX is now an integral part of Windows, with support for all modern video cards. However, the programming API for DirectX still reflects its roots as a game developer’s toolkit, and therefore is rarely used in traditional types of Windows applications. &lt;/p&gt;  &lt;p&gt;&lt;a href="http://msdn.microsoft.com/en-us/directx/default.aspx" target="_blank"&gt;more info&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;&lt;font size="3"&gt;&lt;strong&gt;WPF Rendering&lt;/strong&gt;&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;The internal architecture of WPF has two rendering pipelines, hardware and software. &lt;/p&gt;  &lt;p&gt;&lt;strong&gt;Hardware Rendering Pipeline:&lt;/strong&gt; One of the most important factors in determining WPF performance is that it is render bound—the more pixels you have to render, the greater the performance cost. However, The more rendering that can be offloaded to the graphics processing unit (GPU), the more performance benefits you can gain. &lt;/p&gt;  &lt;p&gt;&lt;strong&gt;Software Rendering Pipeline:&lt;/strong&gt; The WPF software rendering pipeline is entirely CPU bound. WPF implements an optimized, fully-featured software rasterizer (Rasterisation is the task of taking an image described in a vector graphics format and converting it into a raster image (pixels or dots) for output on a video display or printer, or for storage in a bitmap file format.). Fallback to software is seamless any time application functionality cannot be rendered using the hardware rendering pipeline.&lt;/p&gt;  &lt;p&gt;The biggest performance issue you will encounter when rendering in software mode is related to &lt;strong&gt;fill rate&lt;/strong&gt;, which is defined as the number of pixels that you are rendering. If you are concerned about performance in software rendering mode, try to minimize the number of times a pixel is redrawn. For example, if you have an application with a blue background, which then renders a slightly transparent image over it, you will render all of the pixels in the application twice. As a result, it will take twice as long to render the application with the image than if you had only the blue background.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;Forcing Software Rendering&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;Depending on the machine configuration and the application, software-based rendering is &lt;a href="http://blogs.msdn.com/seema/archive/2006/10/25/layered-windows-sw-is-sometimes-faster-than-hw.aspx" target="_blank"&gt;sometimes&lt;/a&gt; faster than hardware.     &lt;br /&gt;A new API was presented in .NET 3.5 SP1 to allow developers to force software rendering in their application (&lt;strong&gt;per window&lt;/strong&gt;) instead of using the GPU. This should provide developers a much better alternative than setting the global registry key and affecting all WPF applications. &lt;/p&gt;  &lt;div style="border-bottom:silver 1px solid;text-align:left;border-left:silver 1px solid;padding-bottom:4px;line-height:12pt;background-color:#f4f4f4;margin:20px 0px 10px;padding-left:4px;width:97.5%;padding-right:4px;font-family:&amp;#39;Courier New&amp;#39;, courier, monospace;direction:ltr;max-height:200px;font-size:8pt;overflow:auto;border-top:silver 1px solid;cursor:text;border-right:silver 1px solid;padding-top:4px;" 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:&amp;#39;Courier New&amp;#39;, 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:&amp;#39;Courier New&amp;#39;, 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;private&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;void&lt;/span&gt; OnLoaded(&lt;span style="color:#0000ff;"&gt;object&lt;/span&gt; sender, EventArgs e)&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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;/pre&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:&amp;#39;Courier New&amp;#39;, 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;if&lt;/span&gt; (ForceSoftware)&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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;/pre&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:&amp;#39;Courier New&amp;#39;, 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;                 HwndSource hwndSource = PresentationSource.FromVisual(&lt;span style="color:#0000ff;"&gt;this&lt;/span&gt;) &lt;span style="color:#0000ff;"&gt;as&lt;/span&gt; HwndSource;&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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;                 HwndTarget hwndTarget = hwndSource.CompositionTarget;&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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;&amp;#160; &lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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:#008000;"&gt;// this is the new WPF API to force render mode. &lt;/span&gt;&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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;                 hwndTarget.RenderMode = RenderMode.SoftwareOnly;&lt;/pre&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:&amp;#39;Courier New&amp;#39;, 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;/pre&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:&amp;#39;Courier New&amp;#39;, 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;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;The &lt;a href="http://msdn.microsoft.com/en-us/library/system.windows.interop.rendermode(VS.100).aspx" target="_blank"&gt;RenderMode&lt;/a&gt; enumeration may be either &lt;em&gt;Default&lt;/em&gt; (use hardware rendering, if possible, otherwise use software rendering) or &lt;em&gt;SoftwareOnly&lt;/em&gt; (use software rendering).&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Display Driver Model&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;WPF provides better performance under the Windows Vista operating system, where it can take advantage of the new Windows Vista Display Driver Model (WDDM). WDDM offers several important enhancements beyond the Windows XP Display Driver Model (XPDM). Most importantly, WDDM allows several GPU operations to be scheduled at once, and it allows video card memory to be paged to normal system memory if you exceed what’s available on the video card. 
  &lt;br /&gt;WPF offers some sort of hardware acceleration to all WDDM (Windows Vista) drivers and to XPDM (Windows XP) drivers that were created after November 2004, which is when Microsoft released new driver development guidelines.&lt;/p&gt;

&lt;p&gt;&lt;font size="3"&gt;&lt;strong&gt;Level of Support&lt;/strong&gt;&lt;/font&gt;&lt;/p&gt;

&lt;p&gt;The goal of WPF is to offload as much of the work as possible on the video card so that complex graphics routines are render-bound (limited by the GPU) rather than processor-bound (limited by your computer’s CPU). 
  &lt;br /&gt;WPF is intelligent enough to use hardware optimizations where possible, but it has a software fallback for everything. So if you run a WPF application on a computer with a legacy video card, the interface will still appear the way you designed it. Of course, the software alternative may be much slower, so you’ll find that computers with older video cards won’t run rich WPF applications very well, especially ones that incorporate complex animations or other intense graphical effects. You might want to consider a design that allows your application to seamlessly switch features when running on different hardware, so that it can take full advantage of each different hardware configuration. &lt;/p&gt;

&lt;p&gt;To achieve this, WPF provides functionality to determine the graphics capability of a system at runtime. Graphics capability is determined by categorizing the video card as one of three rendering capability tiers. WPF exposes an API that allows an application to query the rendering capability tier. Your application can then take different code paths at run time depending on the rendering tier supported by the hardware. &lt;/p&gt;

&lt;p&gt;The features of the graphics hardware that most impact the rendering tier levels are: &lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;Video RAM&lt;/strong&gt; The amount of video memory on the graphics hardware determines the size and number of buffers that can be used for compositing graphics. &lt;/p&gt;
  &lt;/li&gt;

  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;Pixel Shader&lt;/strong&gt; A pixel shader is a graphics processing function that calculates effects on a per-pixel basis. Depending on the resolution of the displayed graphics, there could be several million pixels that need to be processed for each display frame. &lt;/p&gt;
  &lt;/li&gt;

  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;Vertex Shader&lt;/strong&gt; A vertex shader is a graphics processing function that performs mathematical operations on the vertex data of the object. &lt;/p&gt;
  &lt;/li&gt;

  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;Multitexture Support&lt;/strong&gt; Multitexture support refers to the ability to apply two or more distinct textures during a blending operation on a 3D graphics object. The degree of multitexture support is determined by the number of multitexture units on the graphics hardware. &lt;/p&gt;
  &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The pixel shader, vertex shader, and multitexture features are used to define specific DirectX version levels, which, in turn, are used to define the different rendering tiers in WPF. &lt;/p&gt;

&lt;p&gt;The features of the graphics hardware determine the rendering capability of a WPF application. The WPF system defines three rendering tiers: &lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;Rendering Tier 0&lt;/strong&gt; 

      &lt;br /&gt;A rendering tier value of 0 means that there is no graphics hardware acceleration available for the application on the device. At this tier level, developers should assume that all graphics will be rendered by software with no hardware acceleration. This tier&amp;#39;s functionality corresponds to a DirectX version that is less than 7.0. 

      &lt;br /&gt;&lt;/p&gt;
  &lt;/li&gt;

  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;Rendering Tier 1 
        &lt;br /&gt;&lt;/strong&gt;A rendering tier value of 1 means that there is partial graphics hardware acceleration available on the video card.&amp;#160; &lt;br /&gt;

      &lt;br /&gt;The following features and capabilities are hardware accelerated for rendering tier 1: 

      &lt;br /&gt;&lt;/p&gt;

    &lt;ul&gt;
      &lt;li&gt;2D rendering &lt;/li&gt;

      &lt;li&gt;3D rasterization &lt;/li&gt;

      &lt;li&gt;3D anisotrophic filtering &lt;/li&gt;

      &lt;li&gt;3D mip mapping &lt;/li&gt;
    &lt;/ul&gt;

    &lt;p&gt;The following graphics hardware features define rendering tier 1: &lt;/p&gt;

    &lt;ul&gt;
      &lt;li&gt;DirectX version (7.0 =&amp;lt; ver &amp;lt; 9.0) &lt;/li&gt;

      &lt;li&gt;Video RAM (&amp;gt;= 30MB), &lt;/li&gt;

      &lt;li&gt;Multitexture units (&amp;gt;= 2) &lt;/li&gt;
    &lt;/ul&gt;
  &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;
  &lt;br /&gt;&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;Rendering Tier 2 
        &lt;br /&gt;&lt;/strong&gt;A rendering tier value of 2 means that most of the graphics features of WPF should use hardware acceleration.&amp;#160; &lt;br /&gt;

      &lt;br /&gt;The following features and capabilities are hardware accelerated for rendering tier 2: 

      &lt;br /&gt;&lt;/p&gt;

    &lt;ul&gt;
      &lt;li&gt;Tier 1 features &lt;/li&gt;

      &lt;li&gt;Radial gradients &lt;/li&gt;

      &lt;li&gt;3D lighting calculations &lt;/li&gt;

      &lt;li&gt;Text rendering &lt;/li&gt;

      &lt;li&gt;3D anti-aliasing &lt;/li&gt;
    &lt;/ul&gt;

    &lt;p&gt;The following graphics hardware features define rendering tier 2: &lt;/p&gt;

    &lt;ul&gt;
      &lt;li&gt;DirectX version (&amp;gt;= 9.0) &lt;/li&gt;

      &lt;li&gt;Video RAM (&amp;gt;= 120MB) &lt;/li&gt;

      &lt;li&gt;Pixel shader (version &amp;gt;= 2.0) &lt;/li&gt;

      &lt;li&gt;Vertex shader (version &amp;gt;= 2.0) &lt;/li&gt;

      &lt;li&gt;Multitexture units (&amp;gt;= 4) &lt;/li&gt;
    &lt;/ul&gt;
  &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;RenderCapability.Tier Property&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The &lt;a href="http://msdn.microsoft.com/en-us/library/system.windows.media.rendercapability.tier.aspx" target="_blank"&gt;Tier&lt;/a&gt; property allows you to retrieve the rendering tier at application run time. You might choose to scale down 

  &lt;br /&gt;complex effects in the user interface, depending on the level of hardware acceleration that’s available in the client. 

  &lt;br /&gt;There’s one trick, the rendering tier corresponds to the high-order word of the Tier property, so to extract its value from the Tier property, you need to shift it 16 bits: 

  &lt;br /&gt;

  &lt;br /&gt;int renderingTier = (RenderCapability.Tier &amp;gt;&amp;gt; 16); 

  &lt;br /&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;No Acceleration&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The following features and capabilities are &lt;strong&gt;not&lt;/strong&gt; hardware accelerated: &lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;Bitmap effects &lt;/li&gt;

  &lt;li&gt;Printed content &lt;/li&gt;

  &lt;li&gt;Rasterized content that uses &lt;a href="http://msdn.microsoft.com/en-us/library/system.windows.media.imaging.rendertargetbitmap.aspx"&gt;RenderTargetBitmap&lt;/a&gt; &lt;/li&gt;

  &lt;li&gt;Tiled content that uses &lt;a href="http://msdn.microsoft.com/en-us/library/system.windows.media.tilebrush.aspx"&gt;TileBrush&lt;/a&gt; &lt;/li&gt;

  &lt;li&gt;Surfaces that exceed the maximum texture size of the graphics &lt;/li&gt;

  &lt;li&gt;Any operation whose video RAM requirement exceeds the memory of the graphics hardware &lt;/li&gt;

  &lt;li&gt;Layered windows (only on XP) &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;&lt;font size="3"&gt;Graphics Rendering Registry Settings&lt;/font&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;WPF provides registry settings for troubleshooting, debugging, and product support purposes. However, because changes to the registry affect all WPF applications, your application should never alter these registry keys automatically, or during installation.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Disable Hardware Acceleration Option&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;[HKEY_CURRENT_USER\SOFTWARE\Microsoft\Avalon.Graphics\DisableHWAcceleration]&lt;/p&gt;

&lt;p&gt;The disable hardware acceleration option enables you to turn off (set its DOWRD value to 1) hardware acceleration for debugging and test purposes. When you see rendering artifacts in an application, try turning off hardware acceleration. If the artifact disappears, the problem might be with your video driver. 
  &lt;br /&gt;A value of 0 enables hardware acceleration.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Maximum Multisample Value&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;[HKEY_CURRENT_USER\SOFTWARE\Microsoft\Avalon.Graphics\MaxMultisampleType]&lt;/p&gt;

&lt;p&gt;The maximum multisample value enables you to adjust the maximum amount of anti-aliasing of 3-D content (0-16). 
  &lt;br /&gt;WPF defaults to 0 for XPDM drivers and 4 for WDDM drivers.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Required Video Driver Date Setting&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;[HKEY_CURRENT_USER\SOFTWARE\Microsoft\Avalon.Graphics\RequiredVideoDriverDate]&lt;/p&gt;

&lt;p&gt;In November, 2004, Microsoft released a new version of the driver testing guidelines; the drivers written after this date offer better stability. By default, WPF will use the hardware acceleration pipeline for these drivers and will fall back to software rendering for XPDM drivers published before this date.&lt;/p&gt;

&lt;p&gt;The required video driver date setting enables you to specify an alternate minimum date for XPDM drivers. You should only specify a date earlier than November, 2004 if you are confident that your video driver is stable enough to support WPF.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Use Reference Rasterizer Option&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;[HKEY_CURRENT_USER\SOFTWARE\Microsoft\Avalon.Graphics\UseReferenceRasterizer]&lt;/p&gt;

&lt;p&gt;The use reference rasterizer option enables you to force WPF into a simulated hardware rendering mode for debugging: WPF goes into hardware mode, but uses the Microsoft Direct3D reference software rasterizer, d3dref9.dll, instead of an actual hardware device. &lt;/p&gt;

&lt;p&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/aa970912.aspx" target="_blank"&gt;more info&lt;/a&gt;&lt;/p&gt;

&lt;h5&gt;&lt;font size="3"&gt;WPF Performance Profiling Tools&lt;/font&gt;&lt;/h5&gt;

&lt;p&gt;WPF provides (in the Windows SDK tool) a suite of performance profiling tools (WPFPerf.exe) that allow you to analyze the run-time behavior of your application and determine the types of performance optimizations you can apply.&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Event Trace&lt;/strong&gt; - Use for analyzing events and generating event log files. &lt;/li&gt;

  &lt;li&gt;&lt;strong&gt;Perforator&lt;/strong&gt; - Use for analyzing rendering behavior. &lt;/li&gt;

  &lt;li&gt;&lt;strong&gt;Trace Viewer&lt;/strong&gt; - Record, display, and browse Event Tracing for Windows (ETW) log files in a WPF user-interface format. &lt;/li&gt;

  &lt;li&gt;&lt;strong&gt;Visual Profiler&lt;/strong&gt; - Use for profiling the use of WPF services, such as layout and event handling, by elements in the visual tree. &lt;/li&gt;

  &lt;li&gt;&lt;strong&gt;Working Set Viewer&lt;/strong&gt; - Use for analyzing the working set characteristics of your application. &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/aa969767.aspx" target="_blank"&gt;more info&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;DirectX Diagnostic Tool&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The DirectX Diagnostic Tool (~\Windows\System32\Dxdiag.exe) is designed to help you troubleshoot DirectX-related issues.&lt;/p&gt;

&lt;p&gt;&lt;a href="http://support.microsoft.com/kb/190900" target="_blank"&gt;more info&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Sources:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/ms742196.aspx" target="_blank"&gt;Graphics Rendering Tiers&lt;/a&gt; &lt;/li&gt;

  &lt;li&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/aa969767.aspx" target="_blank"&gt;Performance Profiling Tools for WPF&lt;/a&gt; &lt;/li&gt;

  &lt;li&gt;&lt;a href="http://www.apress.com/book/view/1590597826" target="_blank"&gt;Apress - Pro WPF: Windows Presentation Foundation in .NET 3.0&lt;/a&gt; &lt;/li&gt;
&lt;/ul&gt;&lt;img src="http://beta.blogs.microsoft.co.il/aggbug.aspx?PostID=331748" width="1" height="1"&gt;</description><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/WPF/default.aspx">WPF</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/DEV/default.aspx">DEV</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/.NET/default.aspx">.NET</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/Hardware+Acceleration/default.aspx">Hardware Acceleration</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/Performance+Tools/default.aspx">Performance Tools</category></item><item><title>digiTweet – an Open Source WPF Desktop Twitter Client</title><link>http://beta.blogs.microsoft.co.il/blogs/janiv/archive/2009/05/24/digitweet-an-open-source-wpf-desktop-twitter-client.aspx</link><pubDate>Sun, 24 May 2009 14:36:00 GMT</pubDate><guid isPermaLink="false">b5c4f5bc-c09b-4439-a595-91a98c1847df:304436</guid><dc:creator>Janiv Ratson</dc:creator><slash:comments>1</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://beta.blogs.microsoft.co.il/blogs/janiv/rsscomments.aspx?PostID=304436</wfw:commentRss><comments>http://beta.blogs.microsoft.co.il/blogs/janiv/archive/2009/05/24/digitweet-an-open-source-wpf-desktop-twitter-client.aspx#comments</comments><description>&lt;p&gt;I love Twitter.&amp;nbsp; Like many users I have moved away from the website to a client application (Powerful software, combined with the cloud – sound familiar?).&lt;/p&gt;
&lt;p&gt;I used to tweet using TweetDeck and twhirl which can be loaded on every PC, Mac or Ubuntu machine. However, being a .NET and WPF guy, there are a few things that &lt;strong&gt;bug me&lt;/strong&gt; about most Twitter clients.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Most of the Twitter clients run in &lt;a href="http://get.adobe.com/air/" target="_blank"&gt;AIR&lt;/a&gt;, being a great cross-platform (I use Windows only) light-weight (not so light) applications. I’m sure the amazing .NET community can do it better. &lt;/li&gt;
&lt;li&gt;Being a cross-platform application, they give up all the great Windows stuff, especially &lt;a href="http://code.msdn.microsoft.com/Win7DeveloperGuide" target="_blank"&gt;Windows 7&lt;/a&gt;. &lt;/li&gt;
&lt;li&gt;Being a .NET guy, I’m partial to apps that are build with .NET, especially WPF, and I would love to see a Twitter client written in &lt;a href="http://msdn.microsoft.com/en-us/netframework/aa663326.aspx" target="_blank"&gt;WPF&lt;/a&gt; or &lt;a href="http://www.microsoft.com/silverlight/" target="_blank"&gt;Silverlight&lt;/a&gt;. &lt;/li&gt;&lt;/ul&gt;
&lt;p&gt;Now, the only solution to my bothers is the developer community to want it happen. They got the power. This brings us to &lt;strong&gt;&lt;a href="http://www.digitweet.com/" target="_blank"&gt;digiTweet&lt;/a&gt;&lt;/strong&gt;. &lt;br /&gt;digiTweet is an Open Source project, sponsored initially by my team at Microsoft Canada in conjunction with friends at &lt;a href="http://www.digiflare.com/" target="_blank"&gt;Digiflare&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;DigiTweet is obviously a desktop application for Twitter.&amp;nbsp; It is built completely using .NET technologies and takes particular advantage of the power of WPF. Additionally, DigiTweet will be implementing several Windows 7 specific features in the coming weeks. &lt;br /&gt;You can sneak preview it on &lt;a href="http://www.flickr.com/photos/guerchele/tags/digitweet/show/" target="_blank"&gt;flickr&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Why do we need another Twitter client? I think that a WPF powered application, combined with the power of Windows can provide Twitter users with an amazing experience. &lt;br /&gt;This is why the DigiTweet application is an open source project at &lt;a href="http://digitweet.codeplex.com/" target="_blank"&gt;Codeplex&lt;/a&gt;. It brings many innovative developers to contribute to making this the best Twitter client for Windows (and hopefully showcase what WPF can do along the way).&lt;/p&gt;
&lt;p&gt;So, give digiTweet a try.&amp;nbsp; More importantly, &lt;a href="http://digitweet.codeplex.com/Release/ProjectReleases.aspx?ReleaseId=25597#DownloadId=63993" target="_blank"&gt;download the code&lt;/a&gt; and try make it better.&lt;/p&gt;
&lt;p&gt;You can also follow digiTweet’s progress on Twitter @&lt;a href="http://twitter.com/digi_tweet" target="_blank"&gt;digi_tweet&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Janiv.&lt;/p&gt;&lt;img src="http://beta.blogs.microsoft.co.il/aggbug.aspx?PostID=304436" width="1" height="1"&gt;</description><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/WPF/default.aspx">WPF</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/OFFTOPIC/default.aspx">OFFTOPIC</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/Microsoft/default.aspx">Microsoft</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/DEV/default.aspx">DEV</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/Windows+7/default.aspx">Windows 7</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/digiTweet/default.aspx">digiTweet</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/Twitter/default.aspx">Twitter</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/Open+Source/default.aspx">Open Source</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/.NET/default.aspx">.NET</category></item><item><title>Offline WPF .Net Framework 4.0 documentation</title><link>http://beta.blogs.microsoft.co.il/blogs/janiv/archive/2009/05/22/offline-wpf-net-framework-4-0-documentation.aspx</link><pubDate>Fri, 22 May 2009 13:46:21 GMT</pubDate><guid isPermaLink="false">b5c4f5bc-c09b-4439-a595-91a98c1847df:301483</guid><dc:creator>Janiv Ratson</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://beta.blogs.microsoft.co.il/blogs/janiv/rsscomments.aspx?PostID=301483</wfw:commentRss><comments>http://beta.blogs.microsoft.co.il/blogs/janiv/archive/2009/05/22/offline-wpf-net-framework-4-0-documentation.aspx#comments</comments><description>&lt;p&gt;Microsoft has published MSDN docs that are scoped only for WPF 4.0.&amp;#160; &lt;/p&gt;  &lt;p&gt;Want fast WPF help (from the WPF SDK team members) without an internet connection?&lt;/p&gt;  &lt;p&gt;&lt;a href="http://cospire.com/wpf_docs.zip" target="_blank"&gt;Download the WPF CHM&lt;/a&gt;.&lt;/p&gt;  &lt;p&gt;IMPORTANT! If you open the CHM and cannot view content, do the following to resolve the issue:    &lt;br /&gt;- Right-click the CHM file, and then click &amp;quot;Properties&amp;quot;.     &lt;br /&gt;- Click &amp;quot;Unblock&amp;quot;.     &lt;br /&gt;- Double-click the .chm file to open the file.&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;Janiv.&lt;/p&gt;&lt;img src="http://beta.blogs.microsoft.co.il/aggbug.aspx?PostID=301483" width="1" height="1"&gt;</description><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/WPF/default.aspx">WPF</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/Visual+Studio+2010/default.aspx">Visual Studio 2010</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/Offline+Documentaion/default.aspx">Offline Documentaion</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/DEV/default.aspx">DEV</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/.NET+Framework+4.0/default.aspx">.NET Framework 4.0</category></item><item><title>Hello, Hola, مرحبا, Bonjour, 喂, Привет, Hallo, こんにちは, Hej, हैलो, Ciao</title><link>http://beta.blogs.microsoft.co.il/blogs/janiv/archive/2009/05/11/hello-hola-bonjour-hallo-hej-ciao.aspx</link><pubDate>Mon, 11 May 2009 20:58:33 GMT</pubDate><guid isPermaLink="false">b5c4f5bc-c09b-4439-a595-91a98c1847df:289234</guid><dc:creator>Janiv Ratson</dc:creator><slash:comments>4</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://beta.blogs.microsoft.co.il/blogs/janiv/rsscomments.aspx?PostID=289234</wfw:commentRss><comments>http://beta.blogs.microsoft.co.il/blogs/janiv/archive/2009/05/11/hello-hola-bonjour-hallo-hej-ciao.aspx#comments</comments><description>&lt;p&gt;Back to English ...&lt;/p&gt;  &lt;p&gt;Hello Everyone! Welcome to the new kid in the &lt;a href="http://blogs.microsoft.co.il/"&gt;Microsoft Israel Community&lt;/a&gt;.     &lt;br /&gt;It is kind of scary to open a new blog nowadays, as there are only &lt;a href="http://www.alphablogs.net/article/over-14-million-new-blog-posts-per-day"&gt;1.4M new blog posts every day&lt;/a&gt; (June 2008), but &lt;a href="http://blogs.microsoft.co.il/blogs/janiv/about.aspx"&gt;I&lt;/a&gt; believe it is time to share my knowledge and thoughts with you.&lt;/p&gt;  &lt;p&gt;So what is this blog going to be about? That presumably will develop as I do, but my initial idea (and dare I say niche) is to focus on UI development and WPF, with occasional technology stuff thrown in.    &lt;br /&gt;I’ll use this blog to share news stories I find interesting, show some source code from interesting projects, share some tips and tricks, carry weighty discussions on relevant issues, and maybe more.     &lt;br /&gt;My great challenge will be to make this blog a touch more interesting than just a knowledge base.&lt;/p&gt;  &lt;p&gt;So &lt;a&gt;Bookmark &lt;/a&gt;this blog, &lt;a href="mailto:someone@yoursite.com?subject=You%20MUST%20read%20this%20blog" target="_blank"&gt;email&lt;/a&gt; to a friend/colleague or add its &lt;a href="http://feeds2.feedburner.com/JanivRatsonBlog" target="_blank"&gt;RSS feed&lt;/a&gt;, and let’s hit the road for our long trip. And of course, this blog is intended for you, so if at any point you have any comments or suggestions, please &lt;a href="http://blogs.microsoft.co.il/blogs/janiv/contact.aspx" target="_blank"&gt;let me know&lt;/a&gt; so that I can make improvements.&lt;/p&gt;  &lt;p&gt;Until next time …    &lt;br /&gt;&lt;a href="http://blogs.microsoft.co.il/blogs/janiv/about.aspx" target="_blank"&gt;J.&lt;/a&gt;&lt;/p&gt;&lt;img src="http://beta.blogs.microsoft.co.il/aggbug.aspx?PostID=289234" width="1" height="1"&gt;</description><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/WPF/default.aspx">WPF</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/OFFTOPIC/default.aspx">OFFTOPIC</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/Microsoft/default.aspx">Microsoft</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/Community/default.aspx">Community</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/Blog/default.aspx">Blog</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/Technology/default.aspx">Technology</category><category domain="http://beta.blogs.microsoft.co.il/blogs/janiv/archive/tags/Hello/default.aspx">Hello</category></item></channel></rss>