<?xml version='1.0' encoding='UTF-8'?> <rss version='2.0'><channel><title>http://michael.carbenay.info</title><link>http://mike.carbenay.info/</link><language>fr-Fr</language><generator>CPointSoftware e-commerce (weblogs module)</generator><item><title>Two SideShow gadgets</title><link>http://mike.carbenay.info/post-264.htm</link><pubDate>Wed, 16 May 2007 16:39:52 GMT</pubDate><description><![CDATA[<p>For those out there that know what SideShow is - and maybe have one of the first devices that support this protocol, such as the Momento picture frame -, you'll find at the end of this post two little gadgets (my two first I have made) for you to use.</p> <p>The first one <strong>Folder Watch</strong>, will notify you of files created in a folder. Useful, for example, if you have a software that traces its errors in a text file. Its interface is quite simple (screenshots made with the emulator) :</p> <p align="center"><img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="236" src="http://files.blog-engine.net/10/20461.jpg" width="320" border="0"></p> <p align="center"><font size="1">The "glance" display shows how many files you have in the folder and the name of the latest one (this screenshot is in french, but an english version is included).</font></p> <p align="center"><a href="http://files.blog-engine.net/10/21009.jpg" atomicselection="true"><img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="236" src="http://files.blog-engine.net/10/6885.jpg" width="320" border="0"></a></p> <p align="center"><font size="1">and the details page allows you to browse the name of the newest files.</font></p> <p><strong>Server Ping</strong>, the second one&nbsp;allows you to (guess what ?) ping a list of server.</p> <p align="center"><a href="http://files.blog-engine.net/10/38623.jpg" atomicselection="true"><font size="1"><img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="236" src="http://files.blog-engine.net/10/455.jpg" width="320" border="0"></font></a></p> <p align="center"><font size="1">Glance data shows the current state of your servers (All is ok, some are missing, your network is down, etc.) and if you have enough space on the device, which servers have problems</font></p> <p align="center"><a href="http://files.blog-engine.net/10/28537.jpg" atomicselection="true"><font size="1"><img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="236" src="http://files.blog-engine.net/10/22430.jpg" width="320" border="0"></font></a></p> <p align="center"><font size="1">And the details page shows the ping results.</font></p> <p>If you want to try them,&nbsp;just grab the zip file, unzip it in a folder and launch&nbsp;AdminSideShowGadgets.exe.&nbsp;The gadgets will register and you will&nbsp;be provided with a configuration screen &nbsp;:</p> <p align="center"><a href="http://files.blog-engine.net/10/37261.jpg" atomicselection="true"><img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="303" src="http://files.blog-engine.net/10/33445.jpg" width="488" border="0"></a> </p> <p>&nbsp;</p> <blockquote> <p><a href="http://files.blog-engine.net/1/adminsideshowgadgets.zip">Download&nbsp;Sideshow "Admin" gadgets</a>.</p></blockquote>]]></description><guid>http://mike.carbenay.info/post-264.htm</guid></item><item><title>MobilePC Network assistant v0.5</title><link>http://mike.carbenay.info/post-260.htm</link><pubDate>Sat, 21 Apr 2007 11:44:13 GMT</pubDate><description><![CDATA[<p>I don't know about you, but one on the thing that bores me the most about being a "MobilePC" user is that I have to do the same things again and again and again and again… 
</p><p>So, this little app is what I have done in an attempt to remove the pain of being a mobile user. Its only purpose is to react to changes in your network environment and try to set your preferences accordingly. Let's say, for the sake of the example, that you use your laptop in 3 distinct places (at home, at work, and in the bus). You certainly change your default printer about 99 times a week, probably swear about that …. proxy you have at work, etc. etc. etc.
</p><p>Wouldn't it be cool if your laptop just adapted to your environment?
</p><h1>Definitions
</h1><p><strong>NetworkConfiguration </strong>: A network configuration is an environment in which your MobilePC can be. Examples of NetworkConfigurations are : « At Home », « At work », « At client X », « Disconnected ». A NetworkConfiguration is defined by its tests – which identifies the state of network settings and the environment – and its netlets –which are commands to execute in order to configure the system.
</p><p><strong>Tester</strong> : A tester is a class that allows to determine if your MobilePC is in a NetworkConfiguration. Examples : « Is My PC connected to DHCP server 192.168.0.1 ?» A NetworkConfiguration is said « active » if all of its tests pass.
</p><p><strong>Netlet </strong>: A netlet is a command that is executed when a NetworkConfiguration is activated or disactivated. Its purpose is to set the environment up, such as changing the default printer, mapping a network drive or moving files to the desktop/start menu.
</p><h2>How does it work?
</h2><p>A small, notification-area-based, application runs in the background of your session and reacts to changes in your network environment. Using Testers, it selects between the configurations that you have set-up which one is currently active, and configures your systems accordingly.
</p><p>Let's say that you use your laptop in three environments: at home, at work, and on the bus (or anywhere else without a proper network connection); between those three environments, you may want to change some of your settings such as your default printer, the proxy used to connect to Internet, etc. What you need is something like:
</p><div><table style="border-collapse:collapse" border="0"><colgroup><col style="width:208px"/><col style="width:208px"/><col style="width:208px"/></colgroup><tbody valign="top"><tr><td style="padding-left: 7px; padding-right: 7px; border-top:  solid #4f81bd 1.0pt; border-left:  none; border-bottom:  solid #4f81bd 1.0pt; border-right:  none"><p style="text-align: center"><span style="color:#365f91"><strong>Home</strong></span> </p></td><td style="padding-left: 7px; padding-right: 7px; border-top:  solid #4f81bd 1.0pt; border-left:  none; border-bottom:  solid #4f81bd 1.0pt; border-right:  none"><p style="text-align: center"><span style="color:#365f91"><strong>Office</strong></span> </p></td><td style="padding-left: 7px; padding-right: 7px; border-top:  solid #4f81bd 1.0pt; border-left:  none; border-bottom:  solid #4f81bd 1.0pt; border-right:  none"><p style="text-align: center"><span style="color:#365f91"><strong>Everywhere else<br/>(when disconnected)</strong></span></p></td></tr><tr style="background: #d3dfee"><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91">Use my inkjet printer</span> </p></td><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91">Use a big laser printer</span> </p></td><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91">Print to PDF files</span> </p></td></tr><tr><td style="padding-left: 7px; padding-right: 7px"><p><span style="color:#365f91">Connect to the internet thru my isp router</span> </p></td><td style="padding-left: 7px; padding-right: 7px"><p><span style="color:#365f91">Use my corporate proxy</span></p></td><td style="padding-left: 7px; padding-right: 7px"><p><span style="color:#365f91"> </span> </p></td></tr><tr style="background: #d3dfee"><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91">Map Z: to <a href="file:///\\family\share"/></span>\\family\share</p></td><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91"> </span> </p></td><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91"> </span> </p></td></tr><tr><td style="padding-left: 7px; padding-right: 7px; border-bottom:  solid #4f81bd 1.0pt"><p><span style="color:#365f91"> </span> </p></td><td style="padding-left: 7px; padding-right: 7px; border-bottom:  solid #4f81bd 1.0pt"><p><span style="color:#365f91">Get shortcuts to my server or applications on my desktop</span> </p></td><td style="padding-left: 7px; padding-right: 7px; border-bottom:  solid #4f81bd 1.0pt"><p><span style="color:#365f91"> </span> </p></td></tr></tbody></table></div><p>
 </p><p>You just have to configure three distinct NetworkConfigurations, and try to define what distinguish one from another. When you have set-up the Testers that uniquely identifies one configuration, you may add one or more Netlets which will change the state of your system.
</p><div><table style="border-collapse:collapse" border="0"><colgroup><col style="width:208px"/><col style="width:208px"/><col style="width:208px"/></colgroup><tbody valign="top"><tr><td style="padding-left: 7px; padding-right: 7px; border-top:  solid #4f81bd 1.0pt; border-left:  none; border-bottom:  solid #4f81bd 1.0pt; border-right:  none"><p><span style="color:#365f91"><strong>Home</strong></span> </p></td><td style="padding-left: 7px; padding-right: 7px; border-top:  solid #4f81bd 1.0pt; border-left:  none; border-bottom:  solid #4f81bd 1.0pt; border-right:  none"><p style="text-align: center"><span style="color:#365f91"><strong>Office</strong></span> </p></td><td style="padding-left: 7px; padding-right: 7px; border-top:  solid #4f81bd 1.0pt; border-left:  none; border-bottom:  solid #4f81bd 1.0pt; border-right:  none"><p style="text-align: center"><span style="color:#365f91"><strong>Everywhere else<br/>(when disconnected)</strong></span></p></td></tr><tr style="background: #d3dfee"><td colspan="3" style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91">Testers</span></p></td></tr><tr><td style="padding-left: 7px; padding-right: 7px"><p><span style="color:#365f91">There is a network present</span> </p></td><td style="padding-left: 7px; padding-right: 7px"><p><span style="color:#365f91">There is a network present</span></p></td><td style="padding-left: 7px; padding-right: 7px"><p><span style="color:#365f91">There is no network connection</span> </p></td></tr><tr style="background: #d3dfee"><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91">My DHCP Server is 192.168.0.254</span></p></td><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91">My DHCP Server is 10.0.38.253</span></p></td><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91"> </span> </p></td></tr><tr><td style="padding-left: 7px; padding-right: 7px"> </td><td style="padding-left: 7px; padding-right: 7px"><p><span style="color:#365f91">My DNS suffix is mycompany.com</span> </p></td><td style="padding-left: 7px; padding-right: 7px"><p><span style="color:#365f91"> </span> </p></td></tr><tr style="background: #d3dfee"><td colspan="3" style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91">Netlets</span></p></td></tr><tr><td style="padding-left: 7px; padding-right: 7px"><p><span style="color:#365f91">Change default printer to My Inkjet</span> </p></td><td style="padding-left: 7px; padding-right: 7px"><p><span style="color:#365f91">Change default Printer to <a href="file:///\\Server\Printer2"/></span>\\Server\Printer2</p></td><td style="padding-left: 7px; padding-right: 7px"><p><span style="color:#365f91">Change default printer to PDFPrint</span> </p></td></tr><tr style="background: #d3dfee"><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91">Map Drive Z: to <a href="file:///\\family\share"/></span><strong>\\family\share</strong></p></td><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"> </td><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91"> </span> </p></td></tr><tr><td style="padding-left: 7px; padding-right: 7px"> </td><td style="padding-left: 7px; padding-right: 7px"><p><span style="color:#365f91">Copy *.rdp to my Desktop</span> </p></td><td style="padding-left: 7px; padding-right: 7px"> </td></tr><tr style="background: #d3dfee"><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-bottom:  solid #4f81bd 1.0pt; border-right:  none"> </td><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-bottom:  solid #4f81bd 1.0pt; border-right:  none"><p><span style="color:#365f91">Set IE Proxy to 10.0.38.254</span> </p></td><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-bottom:  solid #4f81bd 1.0pt; border-right:  none"> </td></tr></tbody></table></div><p>
 </p><p>A netlet will change to the desired state when a configuration is activated and revert back to the previous state when needed, so you don't have to worry to remove the proxy on IE on the Home profile if it is not set by default.
</p><h1>Configuration
</h1><p>All the configuration of this assistant is done by thru an xml-based settings file which you can edit it from your start menu (Start&gt;All Programs&gt;Network Assistant v0.5&gt;Edit your NetworkConfigurations). Its format is rather simple:
</p><ul><li><div style="text-align: justify">Each NetworkConfiguration must be a child of the root <em>Config</em> element and must have a <em>name</em> attribute.
</div></li><li><div style="text-align: justify">A NetworkConfiguration should have 2 child elements : <em>Tests</em> and <em>Netlets</em>
			</div></li><li><div style="text-align: justify">In <em>Tests</em>, you can put one of the following elements :
</div><ul><li><div style="text-align: justify">IsConnected
</div></li><li><div style="text-align: justify">DnsServer
</div></li><li><div style="text-align: justify">DnsSuffix
</div></li><li><div style="text-align: justify">DhcpServer
</div></li></ul></li><li><div style="text-align: justify">In <em>Netlets</em>, the following child are allowed :
</div><ul><li><div style="text-align: justify">DefaultPrinter
</div></li><li><div style="text-align: justify">ConnectNetworkDrive
</div></li><li><div style="text-align: justify">CopyFiles
</div></li><li><div style="text-align: justify">IEProxy
</div></li><li><div style="text-align: justify">(more netlets will be added later)
</div></li></ul></li></ul><p>A test element (IsConnected, DnsServer…) have always the same format:
</p><p><span style="font-family:Courier New; font-size:8pt">            &lt;<span style="color:#a31515">TestName</span>
			<span style="color:red">value</span>="valueToTest" /&gt;
</span></p><p>
 </p><div><table style="border-collapse:collapse" border="0"><colgroup><col style="width:205px"/><col style="width:205px"/><col style="width:205px"/></colgroup><tbody valign="top"><tr><td style="padding-left: 7px; padding-right: 7px; border-top:  solid #4f81bd 1.0pt; border-left:  none; border-bottom:  solid #4f81bd 1.0pt; border-right:  none"><p><span style="color:#365f91"><strong>Test name</strong></span> </p></td><td style="padding-left: 7px; padding-right: 7px; border-top:  solid #4f81bd 1.0pt; border-left:  none; border-bottom:  solid #4f81bd 1.0pt; border-right:  none"><p><span style="color:#365f91"><strong>Value parameter</strong></span> </p></td><td style="padding-left: 7px; padding-right: 7px; border-top:  solid #4f81bd 1.0pt; border-left:  none; border-bottom:  solid #4f81bd 1.0pt; border-right:  none"><p><span style="color:#365f91"><strong>Remark</strong></span> </p></td></tr><tr style="background: #d3dfee"><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91"><strong>IsConnected</strong></span> </p></td><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91">"true" or "false"</span> </p></td><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91">If you want the test to pass when a network is available use "true", and if you want to test if the MobilePC is in a disconnected state use "false"</span></p></td></tr><tr><td style="padding-left: 7px; padding-right: 7px"><p><span style="color:#365f91"><strong>DhcpServer</strong></span> </p></td><td style="padding-left: 7px; padding-right: 7px"><p><span style="color:#365f91">IP address</span> </p></td><td style="padding-left: 7px; padding-right: 7px"><p><span style="color:#365f91">You must use an IP address (192.168.0.1), using a computer hostname is not supported</span> </p></td></tr><tr style="background: #d3dfee"><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91"><strong>DnsServer</strong></span> </p></td><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91">IP address</span> </p></td><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91">(idem)</span> </p></td></tr><tr><td style="padding-left: 7px; padding-right: 7px; border-bottom:  solid #4f81bd 1.0pt"><p><span style="color:#365f91"><strong>DnsSuffix</strong></span></p></td><td style="padding-left: 7px; padding-right: 7px; border-bottom:  solid #4f81bd 1.0pt"><p><span style="color:#365f91">Dns suffix</span> </p></td><td style="padding-left: 7px; padding-right: 7px; border-bottom:  solid #4f81bd 1.0pt"><p><span style="color:#365f91">Ex : "carbenay.info"</span> </p></td></tr></tbody></table></div><p><br/>The Tests node for the Home configuration is:
</p><p><span style="font-family:Courier New; font-size:8pt">    &lt;<span style="color:#a31515">Tests</span>&gt;
</span></p><p><span style="font-family:Courier New; font-size:8pt">        &lt;<span style="color:#a31515">IsConnected</span>
			<span style="color:red">value</span>="true" /&gt;
</span></p><p><span style="font-family:Courier New; font-size:8pt">        &lt;<span style="color:#a31515">DnsServer</span>
			<span style="color:red">value</span>="192.168.0.1" /&gt;
</span></p><p><span style="font-family:Courier New; font-size:8pt">    &lt;/<span style="color:#a31515">Tests</span>&gt;
</span></p><p>
 </p><p>The netlets have not the same "standard" parameter, and each one is different.
</p><div><table style="border-collapse:collapse" border="0"><colgroup><col style="width:205px"/><col style="width:211px"/><col style="width:205px"/></colgroup><tbody valign="top"><tr><td style="padding-left: 7px; padding-right: 7px; border-top:  solid #4f81bd 1.0pt; border-left:  none; border-bottom:  solid #4f81bd 1.0pt; border-right:  none"><p><span style="color:#365f91"><strong>NetletName</strong></span></p></td><td style="padding-left: 7px; padding-right: 7px; border-top:  solid #4f81bd 1.0pt; border-left:  none; border-bottom:  solid #4f81bd 1.0pt; border-right:  none"><p><span style="color:#365f91"><strong>Parameter</strong></span> </p></td><td style="padding-left: 7px; padding-right: 7px; border-top:  solid #4f81bd 1.0pt; border-left:  none; border-bottom:  solid #4f81bd 1.0pt; border-right:  none"><p><span style="color:#365f91"><strong>Remarks</strong></span> </p></td></tr><tr style="background: #d3dfee"><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91"><strong>DefaultPrinter</strong></span> </p></td><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91">printerName="<em>{PrinterName}</em> "</span></p></td><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"> </td></tr><tr><td style="padding-left: 7px; padding-right: 7px"><p><span style="color:#365f91"><strong>CopyFiles</strong></span> </p></td><td style="padding-left: 7px; padding-right: 7px"><p><span style="color:#365f91">sourceFolder="<em>{Path}</em>"</span></p></td><td style="padding-left: 7px; padding-right: 7px"><p><span style="color:#365f91">The {Path} parameter can include environment variables (such as %USERNAME%, %APPDATA% …) and can also use :
</span></p><p><span style="color:#365f91">%DESKTOP% : path to the current user's desktop
</span></p><p><span style="color:#365f91">(more aliases will be added)</span> </p></td></tr><tr style="background: #d3dfee"><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"> </td><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91">destinationFolder="<em>{Path}</em>"</span></p></td><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91">Idem</span> </p></td></tr><tr><td style="padding-left: 7px; padding-right: 7px"> </td><td style="padding-left: 7px; padding-right: 7px"><p><span style="color:#365f91">searchPattern="<em>{SearchPattern}</em>"</span></p></td><td style="padding-left: 7px; padding-right: 7px"><p><span style="color:#365f91">Ie : "*.rdp", "*.lnk"…</span> </p></td></tr><tr style="background: #d3dfee"><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91"><strong>ConnectNetworkDrive</strong></span> </p></td><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91">localDrive="<em>{DriveLetter}</em>"</span></p></td><td style="padding-left: 7px; padding-right: 7px; border-left:  none; border-right:  none"><p><span style="color:#365f91">Drive letter (in the format X: ) on which to mount the network share</span> </p></td></tr><tr><td style="padding-left: 7px; padding-right: 7px; border-bottom:  solid #4f81bd 1.0pt"> </td><td style="padding-left: 7px; padding-right: 7px; border-bottom:  solid #4f81bd 1.0pt"><p><span style="color:#365f91">remotePath="<em>{RemotePath}</em>"</span></p></td><td style="padding-left: 7px; padding-right: 7px; border-bottom:  solid #4f81bd 1.0pt"><p><span style="color:#365f91">Path to the network share in UNC format (i.e. : \\server\share)</span> </p></td></tr></tbody></table></div><p>
 </p><p>Example :  the Home configuration's Netlets element :
</p><p><span style="font-family:Courier New; font-size:8pt"><span style="color:blue">    &lt;</span><span style="color:#a31515">Netlets</span><span style="color:blue">&gt;
</span></span></p><p><span style="font-family:Courier New; font-size:8pt"><span style="color:blue">        &lt;</span><span style="color:#a31515">DefaultPrinter</span><span style="color:blue">
			</span><span style="color:red">printerName</span><span style="color:blue">=</span>"<span style="color:blue">MyInkjet</span>"<span style="color:blue"> /&gt;
</span></span></p><p><span style="font-family:Courier New; font-size:8pt"><span style="color:blue">        &lt;</span><span style="color:#a31515">CopyFiles</span><span style="color:blue">
			</span></span></p><p style="margin-left: 72pt"><span style="font-family:Courier New; font-size:8pt"><span style="color:red">sourceFolder</span><span style="color:blue">=</span>"<span style="color:blue">%LOCALAPPDATA%\NetworkAwareAssistant\Home\CopyFiles\</span>"<span style="color:blue">
			</span></span></p><p><span style="font-family:Courier New; font-size:8pt"><span style="color:blue">             </span><span style="color:red">destinationFolder</span><span style="color:blue">=</span>"<span style="color:blue">%DESKTOP%</span>"
</span></p><p><span style="font-family:Courier New; font-size:8pt"><span style="color:blue">             </span><span style="color:red">searchPattern</span><span style="color:blue">=</span>"<span style="color:blue">*.rdp</span>"
</span></p><p><span style="color:blue; font-family:Courier New; font-size:8pt">                         /&gt;
</span></p><p><span style="font-family:Courier New; font-size:8pt"><span style="color:blue">        &lt;</span><span style="color:#a31515">ConnectNetworkDrive</span>
		</span></p><p><span style="font-family:Courier New; font-size:8pt"><span style="color:blue">             </span><span style="color:red">localDrive</span><span style="color:blue">=</span>"<span style="color:blue">J:</span>"
</span></p><p><span style="font-family:Courier New; font-size:8pt"><span style="color:blue">             </span><span style="color:red">remotePath</span><span style="color:blue">=</span>"<span style="color:blue">\\FamilyServer\Share</span>"<span style="color:blue"> /&gt;
</span></span></p><p><span style="font-family:Courier New; font-size:8pt"><span style="color:blue">    &lt;/</span><span style="color:#a31515">Netlets</span><span style="color:blue">&gt;
</span></span></p><p>
 </p><p>A future version of NetworkAssistant will include a Control Panel application, but for this first release, you'll have to edit your settings manually.
</p><div><table style="border-collapse:collapse; background: #d3dfee" border="0"><colgroup><col style="width:641px"/></colgroup><tbody valign="top"><tr><td style="padding-left: 7px; padding-right: 7px; border-top:  solid #4f81bd 1.0pt; border-left:  solid #4f81bd 1.0pt; border-bottom:  solid #4f81bd 1.0pt; border-right:  solid #4f81bd 1.0pt"><p style="text-align: center">Download the <a href="ftp://white.creo-ignem.fr/SitesWeb/blogengine.net/files/10/NAst/SourceCode.0.5.5.zip">source code</a> or the <a href="ftp://white.creo-ignem.fr/SitesWeb/blogengine.net/files/10/NAst/NAst-setup.0.5.5.zip">installer</a></p></td></tr></tbody></table></div>]]></description><guid>http://mike.carbenay.info/post-260.htm</guid></item><item><title>A small update to my WPFClock ScreenSaver</title><link>http://mike.carbenay.info/post-231.htm</link><pubDate>Thu, 08 Mar 2007 15:58:23 GMT</pubDate><description><![CDATA[<p>I've just made a small change on the most beautiful - ever - screen saver : my WPFClock ScreenSaver. (Err... yes, it display current time on a dark gray background and that's all... but as it's mine, it must be the cooler screensaver that exists no ?)</p> <p align="center"><img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="306" src="http://files.blog-engine.net/10/47851.jpg" width="450" border="0"></p> <p>If you want to test it : here is the <a href="http://files.blog-engine.net/1/WPFClock2.zip">download link</a>.</p>]]></description><guid>http://mike.carbenay.info/post-231.htm</guid></item><item><title>2 Powershell functions for SMO (Sql Server)</title><link>http://mike.carbenay.info/post-223.htm</link><pubDate>Mon, 05 Mar 2007 23:13:29 GMT</pubDate><description><![CDATA[<p>In the last few month, I often had to execute management operations on Sql Server 2005. While using SQL scripts with SQLCMD is nice (I suppose), my growing fondness for Powershell made me write a few scripts that you may find interesting.</p> <p>The first on is rather simple and will return the SMO object for a non-system database (or multiple database if you use a wildcard).</p> <div class="CodeFormatContainer"><pre class="csharpcode">function get-database($name = <span class="str">"*"</span>)
{
[System.Reflection.Assembly]::LoadWithPartialName
           (<span class="str">"Microsoft.SqlServer.Smo"</span>) | <span class="kwrd">out</span>-<span class="kwrd">null</span>
$_srv=New-Object 
           <span class="str">"Microsoft.SqlServer.Management.Smo.Server"</span> <span class="str">"(local)"</span>
<span class="kwrd">return</span> $_srv.Databases | ?{$_.IsSystemObject -eq 0 -and $_.Name -like $name}
}</pre></div>
<p>A note of advice for powershell scripters here : if you ever do such a wonderful trick as loading an assembly, remember to send the result of your call to Load/LoadWithPartialName to out-null. If you don't do so, these methods will push a AssemblyInfo in the pipeline.</p>
<p>The second script is not really more difficult : it backups a database (or all databases). It should not be used as is (except for small servers with simple databases) in a live environment, but may help you build a more complex backup script if needed.</p>
<div class="CodeFormatContainer"><pre class="csharpcode">function backup-database($dbName, $rootFolder)
{
[System.Reflection.Assembly]::LoadWithPartialName(<span class="str">"Microsoft.SqlServer.Smo"</span>)<br>               | <span class="kwrd">out</span>-<span class="kwrd">null</span>
[System.IO.Directory]::CreateDirectory($rootFolder) | <span class="kwrd">out</span>-<span class="kwrd">null</span>
$_srv=New-Object <span class="str">"Microsoft.SqlServer.Management.Smo.Server"</span> <span class="str">"(local)"</span> 
$_bck=<span class="kwrd">new</span>-<span class="kwrd">object</span> <span class="str">"Microsoft.SqlServer.Management.Smo.Backup"</span>
$_bck.Action = <span class="str">'Database'</span> <br>$_fil=<span class="kwrd">new</span>-<span class="kwrd">object</span> <span class="str">"Microsoft.SqlServer.Management.Smo.BackupDeviceItem"</span>
$_fil.DeviceType=<span class="str">'File'</span>
$_fil.Name=[System.IO.Path]::Combine($rootFolder, $dbName + <span class="str">"-"<br></span>                         + [DateTime]::Today.ToString(<span class="str">"yyyy-MM-dd"</span>)+<span class="str">".bak"</span>)
$_bck.Devices.Add($_fil)
$_bck.Database=$dbName 
$_bck.SqlBackup($_srv)
write-host <span class="str">"Backup of "</span> $dbName <span class="str">" done"</span>
} 

function backup-alldatabase($rootFolder)
{
[System.Reflection.Assembly]::LoadWithPartialName(<span class="str">"Microsoft.SqlServer.Smo"</span>)<br>              | <span class="kwrd">out</span>-<span class="kwrd">null</span>
$_srv=New-Object <span class="str">"Microsoft.SqlServer.Management.Smo.Server"</span> <span class="str">"(local)"</span>
$_srv.Databases |<br>              ?{$_.IsSystemObject -eq 0} |<br>              %{backup-database $_.Name $rootFolder}
} 
</pre></div>]]></description><guid>http://mike.carbenay.info/post-223.htm</guid></item><item><title>MCML : First Contact (again)</title><link>http://mike.carbenay.info/post-227.htm</link><pubDate>Sun, 04 Mar 2007 11:16:16 GMT</pubDate><description><![CDATA[<p>Okay, so we have <a href="http://michael.carbenay.info/mcml-first-contact/post-212.htm">created a (really simple) menu control</a>, the next step is to wrap it all in a reusable control that you could use in all your pages / in another project. Doing so will require only 2 things :</p> <ul> <li>manage&nbsp;keyboard and mouse input  <li>move all the mcml code to a new UI</li></ul> <p>Moving the control to its own UI element is not really difficult, all we&nbsp;need to&nbsp;remember is to add properties for the needed data.</p><pre class="csharpcode">&lt;Mcml 
    xmlns=<span class="str">"http://schemas.microsoft.com/2006/mcml"</span>
    xmlns:me=<span class="str">"Me"</span>
    xmlns:cor=<span class="str">"assembly://MScorLib/System"</span>&gt;
    &lt;UI Name=<span class="str">"MenuPage"</span>&gt;
        &lt;Locals&gt;
            &lt;Choice Name=<span class="str">"TheCommands"</span>&gt;
                &lt;Options&gt;
                    &lt;cor:String String=<span class="str">"Command1"</span> /&gt;
                    &lt;cor:String String=<span class="str">"Command2"</span> /&gt;
                    &lt;cor:String String=<span class="str">"Command3"</span> /&gt;
                &lt;/Options&gt;
            &lt;/Choice&gt;
        &lt;/Locals&gt;
        &lt;Content&gt;
            &lt;ColorFill Content=<span class="str">"LightGray"</span> Layout=<span class="str">"Center"</span>&gt;
                &lt;Children&gt;
                    &lt;me:MyMenu MenuItems=<span class="str">"[TheCommands]"</span> /&gt;
                &lt;/Children&gt;
            &lt;/ColorFill&gt;
        &lt;/Content&gt;
    &lt;/UI&gt;

    &lt;UI Name=<span class="str">"MyMenu"</span>&gt;
        &lt;Properties&gt;
            &lt;Choice Name=<span class="str">"MenuItems"</span> Choice=<span class="str">"$Required"</span> /&gt;
        &lt;/Properties&gt;
        &lt;Content&gt;
            &lt;Repeater Layout=<span class="str">"VerticalFlow"</span> Source=<span class="str">"[MenuItems.Options]"</span>&gt;
                &lt;Content&gt;
                    &lt;me:MyMenuItem 
                        Title=<span class="str">"[RepeatedItem!cor:String]"</span>
                        MyIndex=<span class="str">"[RepeatedItemIndex]"</span>
                        Commands=<span class="str">"[MenuItems]"</span>/&gt;
                &lt;/Content&gt;
            &lt;/Repeater&gt;
        &lt;/Content&gt;
    &lt;/UI&gt;<br>
       ...<br>
&lt;/Mcml&gt;</pre>
<p>Nothing difficult here : just cut &amp; paste the Repeater into a new UI, add a property of type Choice and add a "reference" to the newly created control. Now let's add a little interactivity, shall we ?</p>
<p>As I have hinted in the previous post, you just add keyboard and mouse interaction by adding rules to your object. One of the fundamental rules is :</p><pre class="csharpcode">        &lt;Default Target=<span class="str">"[Input.KeyInteractive]"</span> Value=<span class="str">"true"</span> /&gt;
</pre>
<p>which enables a UI to be keyboard-focusable. The actual process of finding which control will be the next one to gain focus when you press a key is left to MediaCenter itself, so don't bother with it. Whenever an item gains focus, the KeyFocus property of Input is changed from false to true, so you can easily add a rule for event-handling.</p><pre class="csharpcode">        &lt;Condition Source=<span class="str">"[Input.KeyFocus]"</span> SourceValue=<span class="str">"true"</span>&gt;
            &lt;Actions&gt;
                &lt;Set Target=<span class="str">"[Commands.ChosenIndex]"</span> Value=<span class="str">"[MyIndex.Value]"</span> /&gt;
                &lt;Set Target=<span class="str">"[CommandLabel.Font]"</span> Value=<span class="str">"Segoe UI, 24, Bold"</span> /&gt;
                &lt;Set Target=<span class="str">"[CommandLabel.Alpha]"</span> Value=<span class="str">"1"</span> /&gt;
            &lt;/Actions&gt;
        &lt;/Condition&gt;</pre>
<p>For the MyMenuItem class, we just change the selected item (the chosen index from our list of commands) and the formatting of our label. This code is a little bit different from the one I'd shown in my previous post, but I won't explain here what makes this code easier to read but not as powerful as the other one.</p>
<p>If you look at the SDK documentation, you'll see that the InputElement as quite a&nbsp;few properties, some of them beeing really interesting :</p>
<ul>
<li><em>KeyFocusOnMouseEnter</em> can be set to false if you want the focus&nbsp;not to be automatically taken by a control on mouse-over 
<li><em>MouseFocus</em> is set to true when the mouse is over an element. (combined with the previous element, it allows you to create a hover effect like an html A/A:hover css rule) 
<li><em>KeyDeepFocus</em> is set to true if the element or one of its children have the keyboard-focus 
<li><em>MouseDeepFocus</em> is the same but for mouse-focus</li></ul>
<p>Next thing to do : add a click effect to our menu-item (the process of actually doing something will be covered in a future post). This is a little bit more difficult, as there's no EnterPressed or MouseClicked property on the Input element... For this basic interactivity, we'll use a local ClickHandler object, which as its name suggest, just reacts to a "click" (left mouse button, space and enter) and add rules to its Clicking property.</p><pre class="csharpcode">&lt;UI Name=<span class="str">"MyMenuItem"</span>&gt;
    ...
    &lt;Locals&gt;
        &lt;ClickHandler Name=<span class="str">"ClickHandler"</span>/&gt;
    &lt;/Locals&gt;
    &lt;Rules&gt;
        ...
        &lt;Condition Source=<span class="str">"[ClickHandler.Clicking]"</span> SourceValue=<span class="str">"true"</span>&gt;
            &lt;Actions&gt;
                &lt;Set Target=<span class="str">"[CommandLabel.Color]"</span> Value=<span class="str">"Red"</span> /&gt;
            &lt;/Actions&gt;
        &lt;/Condition&gt;
    &lt;/Rules&gt;
    ...
&lt;/UI&gt;</pre>
<p>Now, we'll make it really re-usable by creating a new mcml file, and moving the two controls in it :</p><pre class="csharpcode"><strong>MyMenu.mcml</strong><br>&lt;Mcml 
    xmlns=<span class="str">"http://schemas.microsoft.com/2006/mcml"</span>
    xmlns:me=<span class="str">"Me"</span>
    xmlns:cor=<span class="str">"assembly://MScorLib/System"</span>&gt;
    &lt;UI Name=<span class="str">"MyMenu"</span>&gt;
        &lt;Properties&gt;
            &lt;Choice Name=<span class="str">"MenuItems"</span> Choice=<span class="str">"$Required"</span> /&gt;
        &lt;/Properties&gt;
        &lt;Content&gt;
            &lt;Repeater Layout=<span class="str">"VerticalFlow"</span> Source=<span class="str">"[MenuItems.Options]"</span>&gt;
                &lt;Content&gt;
                    &lt;me:MyMenuItem 
                        Commands=<span class="str">"[MenuItems]"</span>
                        Title=<span class="str">"[RepeatedItem!cor:String]"</span>
                        MyIndex=<span class="str">"[RepeatedItemIndex]"</span>/&gt;
                &lt;/Content&gt;
            &lt;/Repeater&gt;
        &lt;/Content&gt;
    &lt;/UI&gt;
    
    &lt;UI Name=<span class="str">"MyMenuItem"</span>&gt;
        &lt;Properties&gt;
            &lt;Choice Name=<span class="str">"Commands"</span> Choice=<span class="str">"$Required"</span> /&gt;
            &lt;Index Name=<span class="str">"MyIndex"</span> Index=<span class="str">"$Required"</span>/&gt;
            &lt;cor:String Name=<span class="str">"Title"</span> String=<span class="str">"$Required"</span>/&gt;
            &lt;Color Name=<span class="str">"ClickedColor"</span> Color=<span class="str">"Red"</span>/&gt;
        &lt;/Properties&gt;

        &lt;Locals&gt;
            &lt;ClickHandler Name=<span class="str">"ClickHandler"</span>/&gt;
        &lt;/Locals&gt;

        &lt;Rules&gt;
            &lt;Default Target=<span class="str">"[Input.KeyInteractive]"</span> Value=<span class="str">"true"</span> /&gt;
            &lt;Default Target=<span class="str">"[Input.KeyFocusOnMouseEnter]"</span> Value=<span class="str">"false"</span> /&gt;

            &lt;Condition Source=<span class="str">"[ClickHandler.Clicking]"</span> SourceValue=<span class="str">"true"</span>&gt;
                &lt;Actions&gt;
                    &lt;Set Target=<span class="str">"[CommandLabel.Color]"</span> Value=<span class="str">"Red"</span> /&gt;
                &lt;/Actions&gt;
            &lt;/Condition&gt;

            &lt;Condition Source=<span class="str">"[Input.MouseFocus]"</span> SourceValue=<span class="str">"true"</span>&gt;
                &lt;Actions&gt;
                    &lt;Set Target=<span class="str">"[CommandLabel.Alpha]"</span> Value=<span class="str">"0.75"</span> /&gt;
                &lt;/Actions&gt;
            &lt;/Condition&gt;
            &lt;Condition Source=<span class="str">"[Input.KeyFocus]"</span> SourceValue=<span class="str">"true"</span>&gt;
                &lt;Actions&gt;
                    &lt;Set Target=<span class="str">"[Commands.ChosenIndex]"</span> Value=<span class="str">"[MyIndex.Value]"</span> /&gt;
                    &lt;Set Target=<span class="str">"[CommandLabel.Font]"</span> Value=<span class="str">"Segoe UI, 24, Bold"</span> /&gt;
                    &lt;Set Target=<span class="str">"[CommandLabel.Alpha]"</span> Value=<span class="str">"1"</span> /&gt;
                &lt;/Actions&gt;
            &lt;/Condition&gt;
                    &lt;/Rules&gt;
        &lt;Content&gt;
            &lt;Text Alpha=<span class="str">"0.50"</span> 
                Name = <span class="str">"CommandLabel"</span> 
                Content=<span class="str">"[Title]"</span> 
                Color=<span class="str">"White"</span> 
                Font=<span class="str">"Segoe UI, 20"</span>&gt;
            &lt;/Text&gt;
        &lt;/Content&gt;
    &lt;/UI&gt;
&lt;/Mcml&gt;
</pre>
<p>In order to reuse this control (in the same&nbsp;project or another one), you'll need to :</p>
<ul>
<li>add this file to your project, 
<li>add it in the resources.resx file 
<li>add the following line in any mcml file in which you want to use those controls (replacing MyAddin/MyDefaultNamespace )</li></ul><pre class="csharpcode">    &lt;Aggregate Source=<span class="str">"resx://MyAddIn/MyDefaultNamespace.Resources/MyMenu"</span> /&gt;
</pre>
<p>In the next few posts, we'll try to make this menu a full fledged control by adding scrolling, commands, accessibility...</p>
<div class="wlWriterSmartContent" id="0767317B-992E-4b12-91E0-4F059A8CECA8:0c0b51e1-d120-4de8-920d-0ad6783fc591" contenteditable="false" style="padding-right: 0px; display: inline; padding-left: 0px; padding-bottom: 0px; margin: 0px; padding-top: 0px">Technorati tags: <a href="http://technorati.com/tags/Media%20Center" rel="tag">Media Center</a>, <a href="http://technorati.com/tags/MCML" rel="tag">MCML</a>, <a href="http://technorati.com/tags/MCPL" rel="tag">MCPL</a>, <a href="http://technorati.com/tags/Media%20Center%20Extensibilty" rel="tag">Media Center Extensibilty</a></div>]]></description><guid>http://mike.carbenay.info/post-227.htm</guid></item><item><title>MCML : First Contact</title><link>http://mike.carbenay.info/post-226.htm</link><pubDate>Sat, 03 Mar 2007 19:15:41 GMT</pubDate><description><![CDATA[<p></p> <p>For the last view days, I've take some of my spare time to dwell into the new generation of Media Center Extensibility technologies. I've already blogged (and I will do it again with a little more details) about my "Lazy boy server monitoring" tool, but the subject for today is MCML (for Media Center Markup Language).  <p>MCML doesn't really have much in common with XAML (for WPF or WPF/e), which is sad. Having to learn one more description language and its associated bag of trick is pretty difficult, but the learning curve for MCML is not really long or even hard. In this post, I'll try to explain how to create a simple menu control with a few options (read without any need to scroll).  <p>After creating a new Media Center Presentation Layer Application, the project have a Default.mcml file that contains a UI element with some content. The UI element is really important in MCML for it's the root container ofevery graphical element you'll build -&nbsp;like a&nbsp;UserControl in asp.net but with the small difference that pages are also an UI element. Clearing the content from this element will bring you with a good starting point for the menu.</p> <div class="CodeFormatContainer"><pre class="csharpcode">&lt;Mcml 
   xmlns=<span class="str">"http://schemas.microsoft.com/2006/mcml"</span>
           xmlns:me=<span class="str">"Me"</span>&gt;
   &lt;UI Name=<span class="str">"MenuPage"</span>&gt;
      
   &lt;/UI&gt;
&lt;/Mcml&gt;</pre></div>
<p>We'll start by adding a ColorFill in the MenuPage. This control is similar to a simple Border object in WPF and by default use all the available space in its container but have on advantage : it serves as a layout manager too (meaning that you can arrange its children in different ways : center them, make them flow vertically etc.). 
<div class="CodeFormatContainer"><pre class="csharpcode">&lt;Mcml 
   xmlns=<span class="str">"http://schemas.microsoft.com/2006/mcml"</span>
    xmlns:me=<span class="str">"Me"</span>&gt;
   &lt;UI Name=<span class="str">"MenuPage"</span>&gt;
      &lt;Content&gt;
         &lt;ColorFill Content=<span class="str">"LightGray"</span> Layout=<span class="str">"Center"</span>&gt;
            &lt;Children&gt;
               
            &lt;/Children&gt;
         &lt;/ColorFill&gt;
      &lt;/Content&gt;
   &lt;/UI&gt;
&lt;/Mcml&gt;</pre></div>
<p>In MCML, there's nothing like a ListView control or any high-end controls. You'll have to go on with a simple Repeater control and a few tricks, but as you will see, there's nothing really complicated. 
<p>MCML is as much a model/view paradigm as XAML is, so to get a list of menu items to display, we'll need three things : 
<ul>
<li>a control to represent a menu-item, 
<li>a control to host those menu items 
<li>… and a list of menu-items</li></ul>
<p>For the last requirement, we'll keep it simple : MCML contains a special collection of objects (the Choice class), that handles most of the thing we'll need : a list of object, a property to know which one is currently selected and events when one of its property changes. As nothing can be that simple and easy, there's a catch in using this Class : by default, MCML does not know what a string (for example) is… Like WPF, you'll need to add a xml-namespace to reference the assembly which contains those types. 
<p>As the Choice class is not a visual element, you won't be able to add it to a Content or Children property, but, that's not a big deal : the UI allows you to define local "variables". 
<div class="CodeFormatContainer"><pre class="csharpcode">&lt;Mcml 
   xmlns=<span class="str">"http://schemas.microsoft.com/2006/mcml"</span>
    xmlns:me=<span class="str">"Me"</span>
   xmlns:cor=<span class="str">"assembly://MScorLib/System"</span>&gt;
   &lt;UI Name=<span class="str">"MenuPage"</span>&gt;
      &lt;Locals&gt;
         &lt;Choice Name=<span class="str">"TheCommands"</span>&gt;
            &lt;Options&gt;
               &lt;cor:String String=<span class="str">"Command1"</span> /&gt;
               &lt;cor:String String=<span class="str">"Command2"</span> /&gt;
               &lt;cor:String String=<span class="str">"Command3"</span> /&gt;
            &lt;/Options&gt;
         &lt;/Choice&gt;
      &lt;/Locals&gt;
      &lt;Content&gt;
         &lt;ColorFill Content=<span class="str">"LightGray"</span> Layout=<span class="str">"Center"</span>&gt;
            &lt;Children&gt;
               &lt;Repeater Layout=<span class="str">"VerticalFlow"</span> Source=<span class="str">"[TheCommands.Options]"</span>&gt;
                  &lt;Content&gt;
                     &lt;Text Content=<span class="str">"[RepeatedItem!cor:String]"</span> /&gt;
                  &lt;/Content&gt;
               &lt;/Repeater&gt;
            &lt;/Children&gt;
         &lt;/ColorFill&gt;
      &lt;/Content&gt;
   &lt;/UI&gt;
&lt;/Mcml&gt;</pre></div>
<p>As you have certainly guessed, the [Something] notation allows to get the value of a variable (the !-notation is used to do some type casting). So we just created a RepeaterItems which displays the options from the local variable TheCommands, and for each value, displays a text. If you take this mcml snippet and run it into MCML Sampler, you should get something like : 
<p align="center"><img height="250" src="http://files.blog-engine.net/10/9955.gif" width="350"></p>
<p>That's not yet amazing, but it will be ;). 
<p>What we need to do next is to replace the simple Text element with something a little bit more complex (what I want to do is to make items become white when selected and red during a mouse-click/enter-key-press). The easiest way to create such a modern - or even futuristic interface - (:p) is to make a user-control (an new UI element) to display the menu item. 
<div class="CodeFormatContainer"><pre class="csharpcode">&lt;Mcml 
   xmlns=<span class="str">"http://schemas.microsoft.com/2006/mcml"</span>
    xmlns:me=<span class="str">"Me"</span>
   xmlns:cor=<span class="str">"assembly://MScorLib/System"</span>&gt;
   &lt;UI Name=<span class="str">"MenuPage"</span>&gt;
      ...
   &lt;/UI&gt;
   &lt;UI Name=<span class="str">"MyMenuItem"</span>&gt;
       &lt;Content&gt;
         &lt;Text Content=<span class="str">"-not defined-"</span> /&gt;
      &lt;/Content&gt;
   &lt;/UI&gt;
&lt;/Mcml&gt;
</pre></div>
<p>We'll need a way to pass the data from the repeater-item to this control, and that's just what the Properties collection is for. These properties are used in the same way that local variables but can be set be the "caller" (parent) control. 
<div class="CodeFormatContainer"><pre class="csharpcode">&lt;Mcml 
   xmlns=<span class="str">"http://schemas.microsoft.com/2006/mcml"</span>
    xmlns:me=<span class="str">"Me"</span>
   xmlns:cor=<span class="str">"assembly://MScorLib/System"</span>&gt;
   &lt;UI Name=<span class="str">"MyMenuItem"</span>&gt;
      &lt;Properties&gt;
         &lt;Choice Name=<span class="str">"Commands"</span> Choice=<span class="str">"$Required"</span> /&gt;
         &lt;Index Name=<span class="str">"MyIndex"</span> Index=<span class="str">"$Required"</span>/&gt;
         &lt;cor:String Name=<span class="str">"Title"</span> String=<span class="str">"$Required"</span>/&gt;
         &lt;Color Name=<span class="str">"ClickedColor"</span> Color=<span class="str">"Red"</span>/&gt;
      &lt;/Properties&gt;
      &lt;Content&gt;
         &lt;Text Alpha=<span class="str">"0.75"</span> 
            Name = <span class="str">"CommandLabel"</span> 
            Content=<span class="str">"[Title]"</span> 
            Color=<span class="str">"White"</span> 
            Font=<span class="str">"Segoe UI, 20"</span>&gt;
         &lt;/Text&gt;
      &lt;/Content&gt;
   &lt;/UI&gt;
&lt;/Mcml&gt;
</pre></div>
<p>The $Required notation specifies that there is no default value for this property and that the parent should always send a value. Now we just have to change the repeater control : 
<div class="CodeFormatContainer"><pre class="csharpcode">...
&lt;Repeater Layout=<span class="str">"VerticalFlow"</span> Source=<span class="str">"[TheCommands.Options]"</span>&gt;
   &lt;Content&gt;
      &lt;me:MyMenuItem 
         Title=<span class="str">"[RepeatedItem!cor:String]"</span>
         MyIndex=<span class="str">"[RepeatedItemIndex]"</span>
         Commands=<span class="str">"[TheCommands]"</span>/&gt;
   &lt;/Content&gt;
&lt;/Repeater&gt;
...</pre></div>
<p>Okay, we're almost done. In order to get the selected item to be different from the others, we'll need to write some rules. Those rules are almost the equivalent of Triggers in WPF : you can specify a test (of the value of a property/variable) and if this test is true, have MCML apply some changes. 
<p>The rule for displaying the selected item in a different way is : 
<div class="CodeFormatContainer"><pre class="csharpcode">&lt;UI Name=<span class="str">"MyMenuItem"</span>&gt;
   &lt;Rules&gt;
      &lt;Condition Source=<span class="str">"[Commands.ChosenIndex]"</span> SourceValue=<span class="str">"[MyIndex.Value]"</span>&gt;
         &lt;Actions&gt;
            &lt;Set Target=<span class="str">"[CommandLabel.Font]"</span> Value=<span class="str">"Segoe UI, 24, Bold"</span> /&gt;
            &lt;Set Target=<span class="str">"[CommandLabel.Alpha]"</span> Value=<span class="str">"1"</span> /&gt;
         &lt;/Actions&gt;
      &lt;/Condition&gt;
   &lt;/Rules&gt;
   ...
&lt;/UI&gt;</pre></div>
<p>It's rather simple : we just check that the ChosenIndex (from the Choice object) is equal to the Index of the current item, and if it's true, we set two properties to different values. If it's false, the default formatting will stay. If you run the mcml file now, the first element will stand-out, but you won't be able to change the selected element. For doing that, you'll need to add the following rule (we'll see more details about mouse/keyboard interaction in another post) : 
<div class="CodeFormatContainer"><pre class="csharpcode">&lt;UI Name=<span class="str">"MyMenuItem"</span>&gt;
   &lt;Rules&gt;
      &lt;Default Target=<span class="str">"[Input.KeyInteractive]"</span> Value=<span class="str">"true"</span> /&gt;
      &lt;Condition Source=<span class="str">"[Input.KeyFocus]"</span> SourceValue=<span class="str">"true"</span>&gt;
         &lt;Actions&gt;
            &lt;Set Target=<span class="str">"[Commands.ChosenIndex]"</span> Value=<span class="str">"[MyIndex.Value]"</span> /&gt;
         &lt;/Actions&gt;
      &lt;/Condition&gt;
      ...
   &lt;/Rules&gt;
   ...
&lt;/UI&gt;
</pre></div>
<p>It basically tell the run-time that you control is focusable and that you want to change the ChosenIndex (to set it to the item's index) when an item as the focus. You can now run the sample and look at the amazing menu we have done : 
<p align="center"><img height="250" src="http://files.blog-engine.net/10/39233.gif" width="350"></p>
<p>In the next post, we'll look at the way MediaCenter applications can handle keyboard and mouse input. 
<p><em>Complete source</em> 
<div class="CodeFormatContainer"><pre class="csharpcode">&lt;Mcml 
   xmlns=<span class="str">"http://schemas.microsoft.com/2006/mcml"</span>
    xmlns:me=<span class="str">"Me"</span>
   xmlns:cor=<span class="str">"assembly://MScorLib/System"</span>&gt;
   &lt;UI Name=<span class="str">"MenuPage"</span>&gt;
      &lt;Locals&gt;
         &lt;Choice Name=<span class="str">"TheCommands"</span>&gt;
            &lt;Options&gt;
               &lt;cor:String String=<span class="str">"Command1"</span> /&gt;
               &lt;cor:String String=<span class="str">"Command2"</span> /&gt;
               &lt;cor:String String=<span class="str">"Command3"</span> /&gt;
            &lt;/Options&gt;
         &lt;/Choice&gt;
      &lt;/Locals&gt;
      &lt;Content&gt;
         &lt;ColorFill Content=<span class="str">"LightGray"</span> Layout=<span class="str">"Center"</span>&gt;
            &lt;Children&gt;
               &lt;Repeater Layout=<span class="str">"VerticalFlow"</span> <br>                       Source=<span class="str">"[TheCommands.Options]"</span>&gt;
                  &lt;Content&gt;
                     &lt;me:MyMenuItem 
                        Title=<span class="str">"[RepeatedItem!cor:String]"</span>
                        MyIndex=<span class="str">"[RepeatedItemIndex]"</span>
                        Commands=<span class="str">"[TheCommands]"</span>/&gt;
                  &lt;/Content&gt;
               &lt;/Repeater&gt;
            &lt;/Children&gt;
         &lt;/ColorFill&gt;
      &lt;/Content&gt;
   &lt;/UI&gt;
   
   &lt;UI Name=<span class="str">"MyMenuItem"</span>&gt;
      &lt;Properties&gt;
         &lt;Choice Name=<span class="str">"Commands"</span> Choice=<span class="str">"$Required"</span> /&gt;
         &lt;Index Name=<span class="str">"MyIndex"</span> Index=<span class="str">"$Required"</span>/&gt;
         &lt;cor:String Name=<span class="str">"Title"</span> String=<span class="str">"$Required"</span>/&gt;
         &lt;Color Name=<span class="str">"ClickedColor"</span> Color=<span class="str">"Red"</span>/&gt;
      &lt;/Properties&gt;
      &lt;Rules&gt;
         &lt;Default Target=<span class="str">"[Input.KeyInteractive]"</span> <br>               Value=<span class="str">"true"</span> /&gt;
         &lt;Condition Source=<span class="str">"[Input.KeyFocus]"</span> <br>                SourceValue=<span class="str">"true"</span>&gt;
            &lt;Actions&gt;
               &lt;Set Target=<span class="str">"[Commands.ChosenIndex]"</span> <br>                    Value=<span class="str">"[MyIndex.Value]"</span> /&gt;
            &lt;/Actions&gt;
         &lt;/Condition&gt;
         
         &lt;Condition Source=<span class="str">"[Commands.ChosenIndex]"</span> <br>                  SourceValue=<span class="str">"[MyIndex.Value]"</span>&gt;
            &lt;Actions&gt;
               &lt;Set Target=<span class="str">"[CommandLabel.Font]"</span> <br>                  Value=<span class="str">"Segoe UI, 24, Bold"</span> /&gt;
               &lt;Set Target=<span class="str">"[CommandLabel.Alpha]"</span> <br>                  Value=<span class="str">"1"</span> /&gt;
            &lt;/Actions&gt;
         &lt;/Condition&gt;
      &lt;/Rules&gt;
      &lt;Content&gt;
         &lt;Text Alpha=<span class="str">"0.75"</span> 
            Name = <span class="str">"CommandLabel"</span> 
            Content=<span class="str">"[Title]"</span> 
            Color=<span class="str">"White"</span> 
            Font=<span class="str">"Segoe UI, 20"</span>&gt;
         &lt;/Text&gt;
      &lt;/Content&gt;
   &lt;/UI&gt;
&lt;/Mcml&gt;</pre></div>
<p></p>
<div class="wlWriterSmartContent" id="d7bf807d-7bb0-458a-811f-90c51817d5c2:33695b31-7911-4c9b-927c-f2d98fb73490" contenteditable="false" style="padding-right: 0px; display: inline; padding-left: 0px; padding-bottom: 0px; margin: 0px; padding-top: 0px"><p><span class="TagSite">Technorati:</span> <a href="http://technorati.com/tag/Media+Center" rel="tag" class="tag">Media Center</a>, <a href="http://technorati.com/tag/MCML" rel="tag" class="tag">MCML</a>, <a href="http://technorati.com/tag/MCPL" rel="tag" class="tag">MCPL</a>, <a href="http://technorati.com/tag/Media+Center+Extensibilty" rel="tag" class="tag">Media Center Extensibilty</a><br /><!-- StartInsertedTags: Media Center, MCML, MCPL, Media Center Extensibilty :EndInsertedTags --></p></div>]]></description><guid>http://mike.carbenay.info/post-226.htm</guid></item><item><title>My wishlist for OneNote 14</title><link>http://mike.carbenay.info/post-225.htm</link><pubDate>Sat, 03 Mar 2007 13:15:09 GMT</pubDate><description><![CDATA[<p>Now that Office 2007 is released - and what a release - it's time to build a wish-list for the next version ! </p> <p>Here is what I really miss in OneNote and would be delighted to see in the next version :</p> <ul> <li>Visio-like diagrams : it'd be nice to be able to add "intelligent clip-art" to a note&nbsp;: we don't really need all the power of Visio, something a little more simple would be great,&nbsp;simply being able to add a shape and edit it's text-content.  <li>VSTO for OneNote :&nbsp;extensibility is such a&nbsp;good thing  <li>Ribbon like interface  <li>The ability to make an&nbsp;hyperlink&nbsp;of an image.  <li>A bug correction : undo will only work until a section is closed, and a password protected section automatically closes, so if you want to undo something you'd better hurry.  <li>a "user-wide" licence : the licence terms are too restrictive. I'd really appreciate another licence kind (even if its price is x2 or x3) which allows me to use OneNote on more than one computer. Or at least allows me to change the device any time.  <li>xcopy deployment : installing an msi is simple, easy and integrates with gpo, but beeing able to xcopy a software is really a plus and&nbsp;I'm not saying that xcopy deployment should be the main way to deploy OneNote, but only an alternate way.</li></ul> <div class="wlWriterSmartContent" id="d7bf807d-7bb0-458a-811f-90c51817d5c2:af10e726-4e5c-427c-ac3a-98aebb0e53d6" contenteditable="false" style="padding-right: 0px; display: inline; padding-left: 0px; padding-bottom: 0px; margin: 0px; padding-top: 0px"><p><span class="TagSite">Technorati:</span> <a href="http://technorati.com/tag/One+Note" rel="tag" class="tag">One Note</a>, <a href="http://technorati.com/tag/Office+14" rel="tag" class="tag">Office 14</a><br /><!-- StartInsertedTags: One Note, Office 14 :EndInsertedTags --></p></div>]]></description><guid>http://mike.carbenay.info/post-225.htm</guid></item><item><title>Powershell script to create a dev-base from a live-database</title><link>http://mike.carbenay.info/post-222.htm</link><pubDate>Wed, 28 Feb 2007 12:46:31 GMT</pubDate><description><![CDATA[<p></p> <p>Back when I worked for <a href="http://www.promod.fr">Promod</a> (one of my first client), the dev team had a wonderful toy : each monday, the database we used for building applications was updated to reflect the last data from the live database.Since then, I have always tried to mimic this feature for every project that I worked on.</p> <p>The trick was not really pretty : every monday, a database backup was restored from live environnement to the dev one. Then a sometime really long script/sql batch was launched to update the schema (every change that we made to the database had to be put in script in a special folder, and all those scripts were executed every monday)</p> <p>This week, I really wanted to get this thing on a new project but the vbscript-based tool&nbsp;I've used many times before didn't worked for some reason, so I have rewritten the whole thing with Powershell.</p> <p>The script is split in a few parts :</p> <ul> <li>first we have to ensure that no one is locking the database. The dirtiest of tricks is used here : I just shutdown and restart SqlServer, remembering to restart all the dependent services (such as Sql Server Agent) that were running before the restart</li></ul> <div class="CodeFormatContainer"><pre class="csharpcode"> $depserv = (get-service mssqlserver).DependentServices 
              | ?{$_.Status -eq <span class="str">'Started'</span>}
 restart-service mssqlserver -force
 $depserv | start-service</pre></div>
<ul>
<li>a restore database is launched thru osql <strong>[Updated 05-mar-2007 : As many of you may have guessed, the actual copy of the&nbsp;.bak from the backup server should be done before restarting sqlserver -&nbsp;I didn't put it before in this post only for readability.]</strong></li></ul>
<div class="CodeFormatContainer"><pre class="csharpcode">copy \\backupsrv\live\newproject.bak d:\dev\newproject.bak
osql -E -Q <span class="str">"RESTORE DATABASE NewProject from disk=
      'd:\dev\newproject.bak' with replace"</span><br>del d:\dev\newproject.bak</pre></div>
<ul>
<li>a Team Foundation Server-based refresh of the script directory is then triggered</li></ul>
<div class="CodeFormatContainer"><pre class="csharpcode">&amp;($env:tfpath) get newproject\datascripts /r
</pre></div>
<ul>
<li>for each .sql file in the aforesaid directory, powershell just run osql with this file</li></ul>
<div class="CodeFormatContainer"><pre class="csharpcode"> dir ($env:scriptdir)+<span class="str">"\*.sql"</span> 
     |% {osql -E -d NewProject -i $_.FullName}</pre></div>
<p>With less than 10 lines (I had to define the scriptdir &amp; tfpath variables, and to add a little error handling), this script replace an about-150-lines vbscript file, that's pretty amazing !</p>
<div class="wlWriterSmartContent" id="d7bf807d-7bb0-458a-811f-90c51817d5c2:cd7f3921-ff46-4c62-9b13-464087704218" contenteditable="false" style="padding-right: 0px; display: inline; padding-left: 0px; padding-bottom: 0px; margin: 0px; padding-top: 0px"><p><span class="TagSite">Technorati:</span> <a href="http://technorati.com/tag/Powershell" rel="tag" class="tag">Powershell</a>, <a href="http://technorati.com/tag/Powershell+scripts" rel="tag" class="tag">Powershell scripts</a><br /><!-- StartInsertedTags: Powershell, Powershell scripts :EndInsertedTags --></p></div>]]></description><guid>http://mike.carbenay.info/post-222.htm</guid></item><item><title>Lazy-boy server monitoring (1)</title><link>http://mike.carbenay.info/post-221.htm</link><pubDate>Wed, 28 Feb 2007 12:43:45 GMT</pubDate><description><![CDATA[<p>They say : there's no better techie than a lazy techie. Keeping that in mind, I've just put together a small Media Center Add-in which enables me to monitor my servers from my TV.</p> <p align="center">&nbsp;<a href="http://files.blog-engine.net/10/49172.jpg" atomicselection="true"><img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="315" src="http://files.blog-engine.net/10/35049.jpg" width="450" border="0"></a> </p> <p>This add-in (as you can see on the screenshot if your french is not too bad) shows a notification whenever one of my server have issues (the issues are collected by a MOM-like - but really smaller - service and sent to a special "maintenance" server). Clicking on "Afficher le détail" (<em>show me the details</em>) displays the list of errors.</p> <p>With this little project, we will see some of the extensibility features of Vista Media Center. For it to remain as simple as possible (and because I'm not yet fluent in MCML), I'll use an XBAP application to show the details and a small non-visual MCPL add-in for the notification.</p> <p><strong>XBAP Application</strong></p> <p>For this post, let's just say that this application exists, is written&nbsp;as a browser wpf application and looks like this :&nbsp;(I know that it is not really good looking and will try to make it prettier before I do another post about it)</p> <p align="center">&nbsp;<a href="http://files.blog-engine.net/10/20277.jpg" atomicselection="true"><img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="300" src="http://files.blog-engine.net/10/23055.jpg" width="450" border="0"></a> </p> <p>If you want to build a XBAP application for Media Center, there are a few&nbsp;things to remember :&nbsp;</p> <ul> <li>the layout and font-size should be chosen to be usable at&nbsp;10-feet  <li>display resolution and even format is the real unknown :&nbsp;480p, 720i, 1080p or even a mere 800x600, the sheer number of different resolutions is frightening, so viewbox and dynamic layout are your friends  <li>most of the time, your user won't have anything but the remote to use your application, so you'd better make it simple to use and forget the idea of complex data-entry  <li>Media center displays (ugly) on screen-commands when the mouse is moved, so don't forget to make space for them</li></ul> <p><strong>The notification add-in</strong></p> <p>The second project is what displays the notification bar. I've used the <em>Windows Media Center Presentation Layer Application</em> (Microsoft really have a way with names...) which came with the SDK. It provides all the necessary files (and much more) for this project :</p> <ul> <li>an add-in class  <li>a registration file  <li>many other things that won't be used in this particular project</li></ul> <p>As the add-in will run in background, the whole code will be found in the add-in class :</p> <div class="CodeFormatContainer"><pre class="csharpcode">    <span class="kwrd">public</span> <span class="kwrd">class</span> MyAddin : IAddInModule, IAddInEntryPoint
    {
        <span class="kwrd">public</span> <span class="kwrd">void</span> Initialize(Dictionary&lt;<span class="kwrd">string</span>, <span class="kwrd">object</span>&gt; appInfo,<br>               Dictionary&lt;<span class="kwrd">string</span>, <span class="kwrd">object</span>&gt; entryPointInfo)
        {
        }
        <span class="kwrd">public</span> <span class="kwrd">void</span> Uninitialize()
        {
        }
        <span class="kwrd">public</span> <span class="kwrd">void</span> Launch(AddInHost host)
        {<br>          ...
        }
    }</pre></div>
<p>I didn't need to do anything when Initializing / Uninitializing, so only the Launch method will be used.</p>
<div class="CodeFormatContainer"><pre class="csharpcode">        <span class="kwrd">public</span> <span class="kwrd">void</span> Launch(AddInHost host)
        {
            <span class="kwrd">if</span> (!CheckSingleInstance())
                <span class="kwrd">return</span>;</pre><pre class="csharpcode"><br><br><br><br>            _host = host;

            <span class="kwrd">while</span> (<span class="kwrd">true</span>)
            {<br>                NotiftIfErrors();
                Thread.Sleep(30000);
            }
        }</pre></div>
<p>After ensuring that another instance of the add-in is not running - if you use a mutex to do such a test, remember to use a local mutex. If you don't, and use global mutex, the add-in may not run on an extender - the method simply enter an infinite loop which checks for errors and goes to sleep for 30 seconds. I did it quick and dirty (that while(true) is not the prettiest thing in the universe) but I'll try to find a nicer way. What is important is to know that the add-in - except for the call to Initialize and Uninitialize - only lasts as long as its Launch method. You may think that it's loaded and unloaded with Media Center, but that's not true. So say goodbye to timers and any other asynchronous method, and play it simple. (I'm not suggesting that you can't use any async methods, but remember that when the Launch method returns, the process will be terminated)</p>
<p>The&nbsp;NotifyIfErrors method is not realy difficult to write :</p>
<div class="CodeFormatContainer"><pre class="csharpcode">        <span class="kwrd">public</span> <span class="kwrd">void</span> NotifyIfErrors()
        {
            <span class="kwrd">int</span> i = GetUnhandledEventCount();
            <span class="kwrd">if</span> ((i &gt; 0 &amp;&amp; (DateTime.Now - _dtLastEvent).TotalHours &gt; 1) <br>                 || i &gt; _lastCount)
            {
                _lastCount = i;
                _dtLastEvent = DateTime.Now;

                <span class="kwrd">string</span> imagePath = Path.GetTempPath() <br>                      + Guid.NewGuid().ToString(<span class="str">"N"</span>) + <span class="str">".png"</span>;
                Bitmap b = <span class="kwrd">new</span> Bitmap(1, 1);
                b.Save(imagePath, ImageFormat.Png);

                _host.MediaCenterEnvironment.DialogNotification(<br>                    <span class="kwrd">string</span>.Format(<span class="str">"{0} Evenements à traiter"</span>, lastCount),
                    <span class="kwrd">new</span> <span class="kwrd">object</span>[] { <span class="str">"Afficher le detail"</span> },
                    30, imagePath,
                    <span class="kwrd">new</span> DialogClosedCallback(LaunchDialog));
            }
        }
</pre></div>
<p>I won't bother you with the details of the GetUnhandledEventCount, which is pretty straightforward and makes web-service-calls. If there's more issues than the last time the add-in checked or if there is more than an hour since the last notification, a new one will be displayed.</p>
<p>The DialogNotification method requires an image, so for the first version of this add-in, I generate an empty picture (when I said, that this was quick &amp; dirty !). The second and last parameters of this method are important : one for specifying the buttons on the notification bar and the other to add a callback method ofr button-press handling.</p>
<div class="CodeFormatContainer"><pre class="csharpcode">        <span class="kwrd">private</span> <span class="kwrd">void</span> LaunchDialog(DialogResult dr)
        {
           <span class="rem">// TBD</span>
        }</pre></div>
<p>Before we can launch the XBAP, we'll need to put together an xml-file to register the application.</p>
<p>This file contains an application definition and two entry points :</p>
<ul>
<li>One for the notification add-in (placed in the <em>Background</em> category) 
<li>The&nbsp;other for the XBAP, registred in "More Program / Tasks"</li></ul>
<div class="CodeFormatContainer"><pre class="csharpcode">&lt;application 
  title=<span class="str">"MyAddin"</span> 
  id=<span class="str">"{EA231D54-38FE-4f8e-969F-077167EDB442}"</span>&gt;
  &lt;entrypoint 
     id=<span class="str">"{78eb8987-7454-40fe-b7cb-bcc338d13587}"</span> 
     addin=<span class="str">"MyAddinPrj.MyAddIn, MyAddinPrj"</span>
              title=<span class="str">"..."</span>
              description=<span class="str">"..."</span>
              ImageUrl=<span class="str">".\AppIcon.png"</span>&gt;
    &lt;category category=<span class="str">"Background"</span>/&gt;
  &lt;/entrypoint&gt;

  &lt;entrypoint 
  id=<span class="str">"{4E6CDC30-7F35-4b48-AE4C-82F0234ECC24}"</span>
  url=<span class="str">"http://maintenance/admindeploy/admin.xbap"</span>
  title=<span class="str">"Issue Tracking"</span>
  imageUrl=<span class="str">"http://maintenance/admindeploy/admin.png"</span>&gt;
    &lt;category category=<span class="str">"Settings\Tasks"</span> /&gt;
  &lt;/entrypoint&gt;
&lt;/application&gt;
</pre></div>
<p>With the informations contained in this registration xml, the parameters to launch the XBAP - the application and entry point guids - are&nbsp;now known.</p>
<div class="CodeFormatContainer"><pre class="csharpcode">        <span class="kwrd">private</span> <span class="kwrd">void</span> LaunchDialog(DialogResult dr)
        {
            <span class="kwrd">if</span> (dr != DialogResult.Cancel)
            {
                _host.MediaCenterEnvironment.LaunchEntryPoint(
                    <span class="kwrd">new</span> Guid(<span class="str">"{EA231D54-38FE-4f8e-969F-077167EDB442}"</span>),
                    <span class="kwrd">new</span> Guid(<span class="str">"{4E6CDC30-7F35-4b48-AE4C-82F0234ECC24}"</span>));
            }
        }</pre></div>
<p><strong>Putting it all together</strong></p>
<p>Deploying this mini-project is not that simple... Due to security concerns - which don't allow a browser application&nbsp;to connect to any server but the one that host its files -, the XBAP goes to my maintenance server. For the MCPL add-in there are two valid destinations : the GAC or the \windows\ehome directory. I'm more in favor of the second, but if you're building a MSI to deploy your project, the GAC is certainly easier.</p>
<div class="wlWriterSmartContent" id="d7bf807d-7bb0-458a-811f-90c51817d5c2:642fe715-d7cc-45a3-a12b-e72d32a91ca8" contenteditable="false" style="padding-right: 0px; display: inline; padding-left: 0px; padding-bottom: 0px; margin: 0px; padding-top: 0px"><p><span class="TagSite">Technorati:</span> <a href="http://technorati.com/tag/Media+Center" rel="tag" class="tag">Media Center</a>, <a href="http://technorati.com/tag/Media+Center+Add-in" rel="tag" class="tag">Media Center Add-in</a>, <a href="http://technorati.com/tag/Media+Center+Extensibility" rel="tag" class="tag">Media Center Extensibility</a><br /><!-- StartInsertedTags: Media Center, Media Center Add-in, Media Center Extensibility :EndInsertedTags --></p></div>]]></description><guid>http://mike.carbenay.info/post-221.htm</guid></item></channel></rss>