<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>A Dullard's Guide : HDi</title><link>http://blogs.msdn.com/amyd/archive/tags/HDi/default.aspx</link><description>Tags: HDi</description><dc:language>en-US</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>Tokens Gone</title><link>http://blogs.msdn.com/amyd/archive/2008/03/18/tokens-gone.aspx</link><pubDate>Wed, 19 Mar 2008 02:35:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8211827</guid><dc:creator>Amy</dc:creator><slash:comments>7</slash:comments><comments>http://blogs.msdn.com/amyd/comments/8211827.aspx</comments><wfw:commentRss>http://blogs.msdn.com/amyd/commentrss.aspx?PostID=8211827</wfw:commentRss><description>Wow. The Xbox 360 HD DVD emulator was WAY more popular than we had imagined. Josh processed thousands of requests and hopefully a huge number of developers are now out there experimenting with interactivity. But, now we have run out of our token allotment...(&lt;a href="http://blogs.msdn.com/amyd/archive/2008/03/18/tokens-gone.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=8211827" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/amyd/archive/tags/HDi/default.aspx">HDi</category><category domain="http://blogs.msdn.com/amyd/archive/tags/markup/default.aspx">markup</category><category domain="http://blogs.msdn.com/amyd/archive/tags/emulator/default.aspx">emulator</category><category domain="http://blogs.msdn.com/amyd/archive/tags/Silverlight/default.aspx">Silverlight</category></item><item><title>Xbox 360 HD DVD Emulator Request Update</title><link>http://blogs.msdn.com/amyd/archive/2008/03/11/xbox-360-hd-dvd-emulator-request-update.aspx</link><pubDate>Tue, 11 Mar 2008 22:19:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8158065</guid><dc:creator>Amy</dc:creator><slash:comments>4</slash:comments><comments>http://blogs.msdn.com/amyd/comments/8158065.aspx</comments><wfw:commentRss>http://blogs.msdn.com/amyd/commentrss.aspx?PostID=8158065</wfw:commentRss><description>Any of you who made requests for the Xbox 360 HD DVD emulator last week should have received at least an initial email with further instructions on getting access to the emulator support site on http://connect.microsoft.com/ , signing the end user licensing...(&lt;a href="http://blogs.msdn.com/amyd/archive/2008/03/11/xbox-360-hd-dvd-emulator-request-update.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=8158065" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/amyd/archive/tags/HD+DVD/default.aspx">HD DVD</category><category domain="http://blogs.msdn.com/amyd/archive/tags/HDi/default.aspx">HDi</category><category domain="http://blogs.msdn.com/amyd/archive/tags/emulator/default.aspx">emulator</category></item><item><title>Xbox 360 HD DVD Emulator - Now Free</title><link>http://blogs.msdn.com/amyd/archive/2008/03/04/xbox-360-hd-dvd-emulator-now-free.aspx</link><pubDate>Wed, 05 Mar 2008 04:57:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8041039</guid><dc:creator>Amy</dc:creator><slash:comments>26</slash:comments><comments>http://blogs.msdn.com/amyd/comments/8041039.aspx</comments><wfw:commentRss>http://blogs.msdn.com/amyd/commentrss.aspx?PostID=8041039</wfw:commentRss><description>UPDATE 3/18 : The Xbox 360 HD DVD Emulator is no longer available. For more information, please see: http://blogs.msdn.com/amyd/archive/2008/03/18/tokens-gone.aspx The Xbox 360 HD DVD Emulator is now available as a free download on Xbox Live Marketplace...(&lt;a href="http://blogs.msdn.com/amyd/archive/2008/03/04/xbox-360-hd-dvd-emulator-now-free.aspx"&gt;read more&lt;/a&gt;)&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=8041039" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/amyd/archive/tags/HD+DVD/default.aspx">HD DVD</category><category domain="http://blogs.msdn.com/amyd/archive/tags/HDi/default.aspx">HDi</category><category domain="http://blogs.msdn.com/amyd/archive/tags/emulator/default.aspx">emulator</category></item><item><title>Xbox 360 HD DVD Emulator Now Available</title><link>http://blogs.msdn.com/amyd/archive/2007/12/13/xbox-360-hd-dvd-emulator-now-available.aspx</link><pubDate>Thu, 13 Dec 2007 19:02:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:6741033</guid><dc:creator>Amy</dc:creator><slash:comments>1</slash:comments><comments>http://blogs.msdn.com/amyd/comments/6741033.aspx</comments><wfw:commentRss>http://blogs.msdn.com/amyd/commentrss.aspx?PostID=6741033</wfw:commentRss><description>The Xbox 360 HD DVD Emulator is now available!&amp;nbsp; The emulator is downloaded through Xbox LIVE Marketplace on your existing Xbox player.&amp;nbsp; The Xbox 360 HD DVD Emulator can run projects from an optical disc, an external USB drive, or from a network drive, and logs API calls, errors, warnings, and exceptions with time code information to a networked PC.&amp;nbsp; The emulator also comes with support provide through the &lt;A class="" href="https://connect.microsoft.com/site/sitehome.aspx?SiteID=508" target=_blank mce_href="https://connect.microsoft.com/site/sitehome.aspx?SiteID=508"&gt;Microsoft Connect&lt;/A&gt; site. 
&lt;P&gt;&lt;B&gt;Required Hardware:&lt;/B&gt;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Retail &lt;A class="" href="http://www.xbox.com/en-AU/hardware/wheretobuy/)" target=_blank mce_href="http://www.xbox.com/en-AU/hardware/wheretobuy/)"&gt;Xbox 360 or Xbox 360 Elite&lt;/A&gt;&amp;nbsp;(with a hard drive)&lt;/LI&gt;
&lt;LI&gt;&lt;A class="" href="http://www.xbox.com/en-AU/hardware/x/xbox360hddvdplayer/)" target=_blank mce_href="http://www.xbox.com/en-AU/hardware/x/xbox360hddvdplayer/)"&gt;Xbox 360 HD DVD add-on&lt;/A&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;A class="" href="http://www.xbox.com/en-AU/live/memberships/default.htm" target=_blank mce_href="http://www.xbox.com/en-AU/live/memberships/default.htm"&gt;Xbox Live Account&lt;/A&gt; (silver or higher) &lt;/LI&gt;
&lt;LI&gt;A PC running Windows XP SP2 or Vista and &lt;A class="" href="http://www.microsoft.com/downloads/details.aspx?FamilyID=0856eacb-4362-4b0d-8edd-aab15c5e04f5&amp;amp;displaylang=en" target=_blank mce_href="http://www.microsoft.com/downloads/details.aspx?FamilyID=0856eacb-4362-4b0d-8edd-aab15c5e04f5&amp;amp;displaylang=en"&gt;.NET Framework 2.0&lt;/A&gt;&amp;nbsp;for optional logging&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&lt;B&gt;Purchase and Installation:&lt;/B&gt;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Visit &lt;A href="http://www.thisishddvd.com/emulator"&gt;www.ThisIsHDDVD.com/emulator&lt;/A&gt; to purchase a redemption token. &lt;/LI&gt;
&lt;LI&gt;You will receive an email with an Xbox Live redemption token to download the emulator and an invitation for the &lt;A class="" href="https://connect.microsoft.com/site/sitehome.aspx?SiteID=508" target=_blank mce_href="https://connect.microsoft.com/site/sitehome.aspx?SiteID=508"&gt;Microsoft Connect&lt;/A&gt; support site.&lt;/LI&gt;
&lt;LI&gt;Download the PC installation files and best practices document from &lt;A class="" href="https://connect.microsoft.com/site/sitehome.aspx?SiteID=508" target=_blank mce_href="https://connect.microsoft.com/site/sitehome.aspx?SiteID=508"&gt;Microsoft Connect&lt;/A&gt;&lt;/LI&gt;
&lt;UL&gt;
&lt;LI&gt;Enter your Connect invitation ID at &lt;A class="" href="https://connect.microsoft.com/invitationentry.aspx" target=_blank mce_href="https://connect.microsoft.com/invitationentry.aspx"&gt;https://connect.microsoft.com/invitationentry.aspx&lt;/A&gt;&lt;/LI&gt;
&lt;LI&gt;Download the installation file at &lt;A class="" href="https://connect.microsoft.com/Downloads/Downloads.aspx?SiteID=508" target=_blank mce_href="https://connect.microsoft.com/Downloads/Downloads.aspx?SiteID=508"&gt;https://connect.microsoft.com/Downloads/Downloads.aspx?SiteID=508&lt;/A&gt;. &lt;/LI&gt;
&lt;LI&gt;The .msi contains logging software and a CHM help file - &lt;B&gt;READ THE CHM&lt;/B&gt; - There are detailed installation and setup instructions to guide you.&lt;/LI&gt;&lt;/UL&gt;
&lt;LI&gt;Download the emulator to your Xbox&lt;/LI&gt;
&lt;UL&gt;
&lt;LI&gt;On your Xbox, sign into Xbox LIVE &lt;/LI&gt;
&lt;LI&gt;Navigate to the Xbox LIVE Marketplace tab and select Redeem Code. &lt;/LI&gt;
&lt;LI&gt;Enter your redemption code for the HD DVD Emulator. &lt;/LI&gt;
&lt;LI&gt;After successfully redeeming the pre-paid code, select "Yes" to download. &lt;/LI&gt;&lt;/UL&gt;&lt;/UL&gt;
&lt;P mce_keep="true"&gt;Read More at &lt;A href="http://thisishddvd.com/emulator/details.aspx"&gt;http://thisishddvd.com/emulator/details.aspx&lt;/A&gt;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=6741033" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/amyd/archive/tags/HD+DVD/default.aspx">HD DVD</category><category domain="http://blogs.msdn.com/amyd/archive/tags/HDi/default.aspx">HDi</category><category domain="http://blogs.msdn.com/amyd/archive/tags/emulator/default.aspx">emulator</category></item><item><title>Exception Handling</title><link>http://blogs.msdn.com/amyd/archive/2007/12/07/exception-handling.aspx</link><pubDate>Fri, 07 Dec 2007 22:46:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:5943418</guid><dc:creator>Amy</dc:creator><slash:comments>2</slash:comments><comments>http://blogs.msdn.com/amyd/comments/5943418.aspx</comments><wfw:commentRss>http://blogs.msdn.com/amyd/commentrss.aspx?PostID=5943418</wfw:commentRss><description>&lt;P mce_keep="true"&gt;An HD DVD&amp;nbsp;player may throw exceptions during the execution of script, and if not caught will result in a player crash (showing an error code of 0x4094C00C on Toshiba or 0xC667000B on Xbox).&amp;nbsp; While it's always a good idea to check conditions which could cause an exception to be thrown, an exception &lt;EM&gt;could&lt;/EM&gt; still be thrown, so write your code in such a way to catch those exceptions and recover gracefully.&amp;nbsp; &lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;STRONG&gt;Your title should&amp;nbsp;use try-catch exception handling in all entry points including all global code, event handlers, and function callbacks.&lt;/STRONG&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;Detailed information about the conditions under which an exception may be thrown is detailed for each API defined in Annex Z of the DVD Specifications for High Definition Video.&amp;nbsp; So, before making a call to an API, check conditions under which an exception may be thrown.&amp;nbsp; For example, calling XMLParser.parse will throw an exception if XMLParser.status is not equal to XMLParser.READY, so you should&amp;nbsp;check status before proceeding.&lt;/P&gt;
&lt;P mce_keep="true"&gt;While specific exceptions&amp;nbsp;can be thrown based on conditions, do not write script that relies on specific exceptions.&amp;nbsp; Both exceptions and callback status values&amp;nbsp;are meant to be informative.&amp;nbsp; This means that they need only to&amp;nbsp;signify success or failure and not specific information about what precisely caused the failure.&lt;/P&gt;
&lt;P mce_keep="true"&gt;Keep try blocks to small chunks of code and attempt recovery wherever possible.&amp;nbsp; &lt;/P&gt;
&lt;DIV style="COLOR: #333333; BACKGROUND-COLOR: #ffffff"&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;try&lt;/SPAN&gt; &lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;if&lt;/SPAN&gt; (XMLParser.status() == XMLParser.READY)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;XMLParser.parse(&lt;SPAN style="COLOR: #a31515"&gt;"file:///dvddisc/ADV_OBJ/data.xml"&lt;/SPAN&gt;, &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt 0.5in; TEXT-INDENT: 0.5in; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;parseCallback);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;else&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: green"&gt;//parseFailed would be a function that proceeds appropriately&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: green"&gt;//when success path can not be followed&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;parseFailed();&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;} &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;catch&lt;/SPAN&gt; (ex)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: green"&gt;//utility from "Helpful Tracing Routines" that writes diagnostic info&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;TraceError(&lt;SPAN style="COLOR: #a31515"&gt;"EXCEPTION"&lt;/SPAN&gt;, ex, arguments.callee);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: green"&gt;//parseFailed would be a function that proceeds appropriately&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: green"&gt;//when success path can not be followed&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;parseFailed();&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 6pt 0.2in"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;}&lt;/SPAN&gt;&lt;/P&gt;&lt;/DIV&gt;
&lt;P&gt;Because using try-catch may make debugging difficult, you should use conditional compilation around calls to try-catch blocks.&amp;nbsp; Conditional compilation is a proprietary Microsoft extension for Jscript that can be used during development with the Microsoft HDi simulator from the Interactivity Jumpstart Kit, the Xbox HD DVD emulator, and some software players.&amp;nbsp; For more information on using conditional compilation during HDi development, read: &lt;A href="http://blogs.msdn.com/ptorr/archive/2007/06/01/using-conditional-compilation-in-hdi.aspx" mce_href="http://blogs.msdn.com/ptorr/archive/2007/06/01/using-conditional-compilation-in-hdi.aspx"&gt;http://blogs.msdn.com/ptorr/archive/2007/06/01/using-conditional-compilation-in-hdi.aspx&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;As demonstrated above, all catch blocks should also contain diagnostic trace information to further assist during development.&amp;nbsp; For more information on helpful tracing routines, read: &lt;A href="http://blogs.msdn.com/ptorr/archive/2007/06/27/helpful-tracing-routines.aspx" mce_href="http://blogs.msdn.com/ptorr/archive/2007/06/27/helpful-tracing-routines.aspx"&gt;http://blogs.msdn.com/ptorr/archive/2007/06/27/helpful-tracing-routines.aspx&lt;/A&gt;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=5943418" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/amyd/archive/tags/HD+DVD/default.aspx">HD DVD</category><category domain="http://blogs.msdn.com/amyd/archive/tags/HDi/default.aspx">HDi</category><category domain="http://blogs.msdn.com/amyd/archive/tags/script/default.aspx">script</category></item><item><title>Error Codes, Toshiba Edition</title><link>http://blogs.msdn.com/amyd/archive/2007/11/27/error-codes-toshiba-edition.aspx</link><pubDate>Tue, 27 Nov 2007 20:01:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:5817866</guid><dc:creator>Amy</dc:creator><slash:comments>1</slash:comments><comments>http://blogs.msdn.com/amyd/comments/5817866.aspx</comments><wfw:commentRss>http://blogs.msdn.com/amyd/commentrss.aspx?PostID=5817866</wfw:commentRss><description>&lt;P&gt;If you know what an error code means, it can be immensely helpful in diagnosing the problem with your project. Below are some of the more common error codes found on Toshiba Players and their potential cause.&amp;nbsp; There is a similar post for &lt;A class="" href="http://blogs.msdn.com/amyd/archive/2007/11/27/error-codes-xbox-edition.aspx" mce_href="http://blogs.msdn.com/amyd/archive/2007/11/27/error-codes-xbox-edition.aspx"&gt;Xbox HD DVD add-on error codes&lt;/A&gt;. &lt;EM&gt;Note: the contents of this post may change overtime.&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;&lt;EM&gt;Note to Consumers:&lt;/EM&gt;&lt;/STRONG&gt; This blog is targeted at content authors who create all those cool applications for HD DVD and might possibly encounter these errors during development.&amp;nbsp; Of course the hope is that you never see these errors, but if you're reading this, that probably isn't the case.&amp;nbsp; Should you receive an error on your HD DVD player, I would recommend the following:&lt;/P&gt;
&lt;OL&gt;
&lt;LI&gt;&lt;STRONG&gt;Update your player firmware&lt;/STRONG&gt;.&amp;nbsp; The issue you are encountering may already have a fix released that you can easily download using the internet port on the back of your player.&amp;nbsp; For more information, see: &lt;A href="http://www.tacpservice.toshiba.com/ConsumerProductSupport/productupdatesandnotices.asp"&gt;http://www.tacpservice.toshiba.com/ConsumerProductSupport/productupdatesandnotices.asp&lt;STRONG&gt;&lt;FONT color=#000000&gt; &lt;/FONT&gt;&lt;/STRONG&gt;&lt;/A&gt;&lt;BR&gt;&lt;BR&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;STRONG&gt;Clear your persistent storage&lt;/STRONG&gt;.&amp;nbsp; Some discs download new content and should there be a problem with that download, the disc may not play correctly.&amp;nbsp; You would only need to clear the persistent storage for that particular title (not all of your titles).&amp;nbsp; For more information, see: &lt;A href="http://www.universalhidef.com/support_errors.aspx#DeletePersistentStorage&amp;nbsp;"&gt;http://www.universalhidef.com/support_errors.aspx#DeletePersistentStorage&lt;STRONG&gt;&amp;nbsp;&lt;/STRONG&gt;&lt;/A&gt;&lt;BR&gt;&lt;BR&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;STRONG&gt;Exchange the Disc&lt;/STRONG&gt;.&amp;nbsp; If a specific disc will not play, it could be a bad disc.&amp;nbsp; It may have been scratched or there may be an anomaly on the disc that prevents it from being read by the player.&amp;nbsp; Most retailers will allow you to exchange a bad disc for a new copy of the same title.&lt;BR&gt;&lt;BR&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;STRONG&gt;Contact Toshiba&lt;/STRONG&gt;.&amp;nbsp; When all else fails, call customer support and ask them what to do.&amp;nbsp; &lt;A href="http://www.tacp.toshiba.com/customersupport/contact.asp"&gt;http://www.tacp.toshiba.com/customersupport/contact.asp&lt;/A&gt;&lt;BR&gt;&lt;/LI&gt;&lt;/OL&gt;
&lt;TABLE class="" style="WIDTH: 500px" cellSpacing=0 cellPadding=0 border=1&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD class=""&gt;
&lt;P&gt;&lt;STRONG&gt;Error Code&lt;/STRONG&gt;&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P&gt;&lt;STRONG&gt;Description&lt;/STRONG&gt;&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P&gt;&lt;STRONG&gt;Possible Causes&lt;/STRONG&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;0x40**C00B&lt;/P&gt;
&lt;P&gt;0x408BC00B&lt;/P&gt;
&lt;P&gt;0x4094C00B&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;Resource Load Failure&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;Playlist is referencing a resource that does not exist or with a size attribute that is too small&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;0x40**C00C&lt;/P&gt;
&lt;P&gt;0x408BC00C&lt;/P&gt;
&lt;P&gt;0x4094C00C&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;Script Failure&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;Script is throwing an exception that is unhandled. Make sure to &lt;A class="" href="http://blogs.msdn.com/amyd/archive/2007/12/07/exception-handling.aspx" mce_href="http://blogs.msdn.com/amyd/archive/2007/12/07/exception-handling.aspx"&gt;use try-catch blocks in your script&lt;/A&gt;.&lt;/P&gt;
&lt;P&gt;Script is missing a semicolon - run the validator on your project &lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;0x40**C00D&lt;/P&gt;
&lt;P&gt;0x408BC00D&lt;/P&gt;
&lt;P&gt;0x4094C00D &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;Unknown markup or script error&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;This is a sort of "catch all" error.&amp;nbsp; If it happens immediately, the format of part of your script may not be valid.&amp;nbsp; &lt;/P&gt;
&lt;P&gt;If this erorr happens after your app has run for a while,&amp;nbsp;this&amp;nbsp;could be&amp;nbsp;an indicator that the player has run out of memory.&amp;nbsp; Check your code for possible memory leaks, particularly those resulting from &lt;A class="" href="http://blogs.msdn.com/ptorr/archive/2007/08/29/using-timers-effectively-in-hdi.aspx" target=_blank mce_href="http://blogs.msdn.com/ptorr/archive/2007/08/29/using-timers-effectively-in-hdi.aspx"&gt;closures and circular references&lt;/A&gt;.&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;0x40**C2**&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;Playlist Load issues&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;0x40**C201&lt;/P&gt;
&lt;P&gt;0x408BC201&lt;/P&gt;
&lt;P&gt;0x4094C201&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;AACS Error for playlist loading&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;0x40**C202&lt;/P&gt;
&lt;P&gt;0x408BC202&lt;/P&gt;
&lt;P&gt;0x4094C202&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;Fatal Error of AACS&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;0x40**C203&lt;/P&gt;
&lt;P&gt;0x408BC203&lt;/P&gt;
&lt;P&gt;0x4094C203&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;Read/Parse Error of playlist file &lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;0x40**4203&lt;/P&gt;
&lt;P&gt;0x408B4203&lt;/P&gt;
&lt;P&gt;0x40944203&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;AACS Read/Parse Error of playlist file &lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;AACS key does match key used to encrypt playlist&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;0x40**C5**&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;Video Playback Errors&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;0x40**C504&lt;/P&gt;
&lt;P&gt;0x408BC504&lt;/P&gt;
&lt;P&gt;0x4094C504&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;Video Controller Error &lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;titleDuration of PrimaryAudioVideoClip is too long&lt;/P&gt;
&lt;P&gt;EVOB is missing&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;0x40**C8**&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;Resource Errors&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;0x40**46**&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;Graphics Errors&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;0x40**C601&lt;/P&gt;
&lt;P&gt;0x408BC601&lt;/P&gt;
&lt;P&gt;0x4094C601&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;Pixel Buffer Overflow &lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;Pixel buffer is impacted by all graphics (PNGs and JPEGs) and render font glyphs in all loaded applications must not exceed 2x1920x1080 ( 4,147,200 pixels) &lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;0x40**C7**&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;Network Errors&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;0x40**C701&lt;/P&gt;
&lt;P&gt;0x408BC701&lt;/P&gt;
&lt;P&gt;0x4094C701&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;DiscID missing from DISCID.DAT&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;Run the DiscID creation tool that ships with the &lt;A class="" href="http://www.microsoft.com/downloads/details.aspx?FamilyId=F8ADA3F5-0EC6-4392-84AB-CB4860DB30ED&amp;amp;displaylang=en" mce_href="http://www.microsoft.com/downloads/details.aspx?FamilyId=F8ADA3F5-0EC6-4392-84AB-CB4860DB30ED&amp;amp;displaylang=en"&gt;interactivity jumpstart kit&lt;/A&gt; with the following parameters (adjust GUIDs as needed):&lt;/P&gt;
&lt;P&gt;"C:\Program Files\HD DVD Interactivity Jumpstart\Tools\CreateDISCID.exe" -c DISCID.DAT &lt;/P&gt;
&lt;P&gt;-provider "FFFFFFFF-FFFF-FFFF-FFFF-FFFFFFFFFFF1" &lt;/P&gt;
&lt;P&gt;-content "FFFFFFFF-FFFF-FFFF-FFFF-FFFFFFFFFFF2" &lt;/P&gt;
&lt;P&gt;-disc "FFFFFFFF-FFFF-FFFF-FFFF-FFFFFFFFFFF3"&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;0x81000C03&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;Markup Resource Load Failure&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;A graphic referenced in the markup may be missing from resources. &lt;/P&gt;
&lt;P&gt;A markup element containing text could not be released at the end of an application&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;0x10004050&lt;/P&gt;
&lt;P&gt;0x200bc601&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;Possible internal player issue&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;Contact Toshiba&lt;BR&gt;&lt;A href="http://www.tacp.toshiba.com/customersupport/contact.asp"&gt;http://www.tacp.toshiba.com/customersupport/contact.asp&lt;/A&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;0x2007c5c2&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;Wrong Firmware Version&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;Update Player Firmware&lt;BR&gt;&lt;A href="http://tacp.toshiba.com/tacpassets-images/notices/hddvd-updateingfirmware.asp"&gt;http://tacp.toshiba.com/tacpassets-images/notices/hddvd-updateingfirmware.asp&lt;/A&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/SPAN&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=5817866" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/amyd/archive/tags/HD+DVD/default.aspx">HD DVD</category><category domain="http://blogs.msdn.com/amyd/archive/tags/HDi/default.aspx">HDi</category><category domain="http://blogs.msdn.com/amyd/archive/tags/emulator/default.aspx">emulator</category></item><item><title>Error Codes, Xbox Edition</title><link>http://blogs.msdn.com/amyd/archive/2007/11/27/error-codes-xbox-edition.aspx</link><pubDate>Tue, 27 Nov 2007 20:00:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:5817870</guid><dc:creator>Amy</dc:creator><slash:comments>1</slash:comments><comments>http://blogs.msdn.com/amyd/comments/5817870.aspx</comments><wfw:commentRss>http://blogs.msdn.com/amyd/commentrss.aspx?PostID=5817870</wfw:commentRss><description>&lt;P&gt;If you know what an error code means, it can be immensely helpful in diagnosing the problem with your project.&amp;nbsp; Below are some of the more common error codes found on the Xbox HD DVD add on and their potential cause.&amp;nbsp; There is a similar post for &lt;A class="" href="http://blogs.msdn.com/amyd/archive/2007/11/27/error-codes-toshiba-edition.aspx" mce_href="http://blogs.msdn.com/amyd/archive/2007/11/27/error-codes-toshiba-edition.aspx"&gt;Toshiba player error codes&lt;/A&gt;.&amp;nbsp; &lt;EM&gt;Note: the contents of this post may change overtime.&lt;/EM&gt; &lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;&lt;EM&gt;Note to Consumers:&lt;/EM&gt;&lt;/STRONG&gt; This blog is targeted at content authors who create all those cool applications for HD DVD and might possibly encounter these errors during development.&amp;nbsp; Of course the hope is that you never see these errors, but if you're reading this, that probably isn't the case.&amp;nbsp; Should you receive an error on your HD DVD player, I would recommend the following:&lt;/P&gt;
&lt;OL&gt;
&lt;LI&gt;&lt;STRONG&gt;Update your player firmware&lt;/STRONG&gt;.&amp;nbsp; Make sure your firmware is up-to-date.&amp;nbsp; For more information, see: &lt;A href="http://www.xbox.com/en-us/hardware/x/xbox360hddvdplayer/download.htm#liveupdate"&gt;http://www.xbox.com/en-us/hardware/x/xbox360hddvdplayer/download.htm#liveupdate&lt;/A&gt;&lt;A href="http://www.tacpservice.toshiba.com/ConsumerProductSupport/productupdatesandnotices.asp"&gt;&lt;STRONG&gt;&lt;FONT color=#000000&gt;&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/A&gt;&lt;BR&gt;&lt;BR&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;STRONG&gt;Clear your persistent storage&lt;/STRONG&gt;.&amp;nbsp; Some discs download new content and should there be a problem with that download, the disc may not play correctly.&amp;nbsp; You would only need to clear the persistent storage for that particular title (not all of your titles).&amp;nbsp; &lt;BR&gt;&lt;BR&gt;1.&amp;nbsp;Launch the Xbox dashboard &lt;BR&gt;2.&amp;nbsp;Navigate to the System blade &lt;BR&gt;3.&amp;nbsp;Select Memory &lt;BR&gt;4.&amp;nbsp;Choose HD DVD&lt;BR&gt;&lt;BR&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;STRONG&gt;Read Andy's Troubleshooting Guides&lt;/STRONG&gt;.&amp;nbsp; &lt;BR&gt;General: &lt;A href="http://blogs.msdn.com/andypennell/archive/2007/10/25/xbox-360-hd-dvd-drive-general-troubleshooting.aspx"&gt;http://blogs.msdn.com/andypennell/archive/2007/10/25/xbox-360-hd-dvd-drive-general-troubleshooting.aspx&lt;/A&gt;&lt;BR&gt;Movie Specific: &lt;A href="http://blogs.msdn.com/andypennell/archive/2007/10/25/xbox-360-hd-dvd-drive-movie-specific-known-issues.aspx"&gt;http://blogs.msdn.com/andypennell/archive/2007/10/25/xbox-360-hd-dvd-drive-movie-specific-known-issues.aspx&lt;/A&gt;&lt;STRONG&gt;&amp;nbsp;&lt;BR&gt;&lt;BR&gt;&lt;/STRONG&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;STRONG&gt;Check Your Cables.&lt;/STRONG&gt;&amp;nbsp;&amp;nbsp;The add-on drive connects&amp;nbsp;to the Xbox with a&amp;nbsp;USB cable.&amp;nbsp;&amp;nbsp;Try a different cable.&lt;BR&gt;&lt;STRONG&gt;&amp;nbsp;&lt;/STRONG&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;STRONG&gt;Exchange the Disc&lt;/STRONG&gt;.&amp;nbsp; If a specific disc will not play, it could be a bad disc.&amp;nbsp; It may have been scratched or there may be an anomaly on the disc that prevents it from being read by the player.&amp;nbsp; Most retailers will allow you to exchange a bad disc for a new copy of the same title.&lt;BR&gt;&lt;BR&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;STRONG&gt;Contact Support&lt;/STRONG&gt;.&amp;nbsp; When all else fails, call customer support and ask them what to do.&amp;nbsp; &lt;A href="http://www.xbox.com/en-US/support/contact/?WT.svl=nav"&gt;http://www.xbox.com/en-US/support/contact/?WT.svl=nav&lt;/A&gt;&lt;BR&gt;&lt;/LI&gt;&lt;/OL&gt;
&lt;TABLE class="" style="WIDTH: 500px" cellSpacing=0 cellPadding=0 border=1&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD class=""&gt;
&lt;P&gt;Error Code&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P&gt;Description&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P&gt;Possible Causes&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class=""&gt;
&lt;P&gt;0x86670001&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P&gt;XPLAYER_W_ACTION_NOT_AVAILABLE&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class=""&gt;
&lt;P&gt;0x86670002&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P&gt;XPLAYER_W_NETWORK_UNSUPPORTED&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class=""&gt;
&lt;P&gt;0x86670003&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P&gt;XPLAYER_W_SUBVIDEO_UNSUPPORTED&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class=""&gt;
&lt;P&gt;0xC6670001&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P&gt;XPLAYER_E_READ&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class=""&gt;
&lt;P&gt;0xC6670002&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P&gt;XPLAYER_E_PARENTAL&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class=""&gt;
&lt;P&gt;0xC6670003&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P&gt;XPLAYER_E_REGION&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class=""&gt;
&lt;P&gt;0xC6670004&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P&gt;XPLAYER_E_DRM_VIOLATION_STOP&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class=""&gt;
&lt;P&gt;0xC6670005&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P&gt;XPLAYER_E_INCORRECT_SYSVER&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class=""&gt;
&lt;P&gt;0xC6670006&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P&gt;XPLAYER_E_IXP_PROVIDER_FAILED&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class=""&gt;
&lt;P&gt;0xC6670007&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P&gt;XPLAYER_E_SECURE_ACCESS_FAILED&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class=""&gt;
&lt;P&gt;0xC6670008&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P&gt;XPLAYER_E_VCP_FAILED&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class=""&gt;
&lt;P&gt;0xC6670009&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P&gt;XPLAYER_E_PRIVATE_FAILURE&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class=""&gt;
&lt;P&gt;0xC667000A&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P&gt;XPLAYER_E_CANT_LOAD_RESOURCE&lt;/P&gt;&lt;/TD&gt;
&lt;TD class=""&gt;
&lt;P&gt;Playlist is referencing a resource that does not exist or with a size attribute that is too small&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;0xC667000B&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;XPLAYER_E_SCRIPT_FAILED&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;Script is throwing an exception that is unhandled.&amp;nbsp; Make sure to use try-catch blocks in your script.&lt;/P&gt;
&lt;P&gt;Script is missing a semicolon - run the validator on your project&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;0xC667000C&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;XPLAYER_E_FILE_INCOMPLETE&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top" colSpan=2&gt;
&lt;P&gt;THERE WAS A PROBLEM WITH &lt;BR&gt;LICENSING FOR THIS CONTENT&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;There could be a legitimate problem with the licensing on your content. Or, this could be a result of the player has run out of memory due to a memory leak. Check your code for possible memory leaks, particularly those resulting from &lt;A class="" href="http://blogs.msdn.com/ptorr/archive/2007/08/29/using-timers-effectively-in-hdi.aspx" mce_href="http://blogs.msdn.com/ptorr/archive/2007/08/29/using-timers-effectively-in-hdi.aspx"&gt;closures and circular references&lt;/A&gt;&amp;nbsp;with timers and HTTPClients.&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top" colSpan=2&gt;
&lt;P&gt;CANNOT READ DISC&lt;/P&gt;&lt;/TD&gt;
&lt;TD class="" style="VERTICAL-ALIGN: top"&gt;
&lt;P&gt;Bad connection: Try playing a DVD or using a different USB cable&lt;BR&gt;Bad disc: Try playing a different HD DVD&lt;BR&gt;&lt;BR&gt;&lt;A href="http://support.microsoft.com/kb/927407/en-us"&gt;http://support.microsoft.com/kb/927407/en-us&lt;/A&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;
&lt;DIV&gt;&lt;/DIV&gt;&lt;BR&gt;
&lt;P&gt;Additional Xbox HD DVD add-on support can be found at:&lt;/P&gt;
&lt;P&gt;&lt;A class="" href="http://blogs.msdn.com/andypennell/archive/2007/10/25/xbox-360-hd-dvd-drive-general-troubleshooting.aspx" mce_href="http://blogs.msdn.com/andypennell/archive/2007/10/25/xbox-360-hd-dvd-drive-general-troubleshooting.aspx"&gt;Trouble shooting tips from Andy Pennell&lt;/A&gt;&lt;BR&gt;&lt;A class="" href="http://blogs.msdn.com/andypennell/archive/2007/10/25/xbox-360-hd-dvd-drive-movie-specific-known-issues.aspx" mce_href="http://blogs.msdn.com/andypennell/archive/2007/10/25/xbox-360-hd-dvd-drive-movie-specific-known-issues.aspx"&gt;Specific movie issues&lt;/A&gt;&lt;BR&gt;&lt;A class="" href="http://support.microsoft.com/kb/927407/en-us" mce_href="http://support.microsoft.com/kb/927407/en-us"&gt;Cannot read disc, but no error code&lt;/A&gt;&lt;BR&gt;&lt;A class="" href="http://support.microsoft.com/kb/927345/en-us" mce_href="http://support.microsoft.com/kb/927345/en-us"&gt;How to use the Xbox HD DVD add-on&lt;/A&gt;&lt;BR&gt;&lt;A class="" href="http://support.microsoft.com/kb/940310/en-us" mce_href="http://support.microsoft.com/kb/940310/en-us"&gt;Modifyting network settings&lt;/A&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=5817870" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/amyd/archive/tags/HD+DVD/default.aspx">HD DVD</category><category domain="http://blogs.msdn.com/amyd/archive/tags/HDi/default.aspx">HDi</category><category domain="http://blogs.msdn.com/amyd/archive/tags/emulator/default.aspx">emulator</category></item><item><title>Advanced Subtitles</title><link>http://blogs.msdn.com/amyd/archive/2007/11/21/advanced-subtitles.aspx</link><pubDate>Thu, 22 Nov 2007 02:28:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:6460835</guid><dc:creator>Amy</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/amyd/comments/6460835.aspx</comments><wfw:commentRss>http://blogs.msdn.com/amyd/commentrss.aspx?PostID=6460835</wfw:commentRss><description>&lt;P&gt;In HD DVD subtitling can be done via a subpicture stream or an Advanced Subtitle.&amp;nbsp; An advanced subtitle is very similar in structure to an advanced application.&amp;nbsp; It has a manifest, markup file, and font and is declared with its resources in the playlist.&amp;nbsp; But, an advanced subtitle has some unique characteristics as well.&amp;nbsp; &lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;The markup for an advanced subtitle uses the .xas extension rather than .xmu. &lt;/LI&gt;
&lt;LI&gt;The markup may not contain event, area, button, input, or option elements. &lt;/LI&gt;
&lt;LI&gt;Inline styles are not permitted. &lt;/LI&gt;
&lt;LI&gt;The markup may never receive focus. &lt;/LI&gt;
&lt;LI&gt;An advanced subtitle may not use script files.&lt;/LI&gt;
&lt;LI&gt;An advanced subtitle is rendered as part of the sub-picture plane and not the graphics plane so zOrder may not be modified&lt;/LI&gt;
&lt;LI&gt;An advanced subtitle may not be active at the same time as a subpicture subtitle.&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;One of the great things about advanced subtitles is that they can be downloaded and run in time with the movie after the disc ships.&amp;nbsp; This could significantly increase the potential audience for your movie.&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;STRONG&gt;Playlist Reference&lt;BR&gt;&lt;/STRONG&gt;An advanced subtitle in a playlist is slightly different from and advanced application in that it must include track information and many not specify zOrder.&lt;/P&gt;
&lt;DIV style="COLOR: #333333; BACKGROUND-COLOR: #ffffff"&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: #a31515; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;AdvancedSubtitleSegment&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;titleTimeBegin&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;=&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;"&lt;SPAN style="COLOR: blue"&gt;00:00:00:00&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;titleTimeEnd&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;=&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;02:00:00:00&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;src&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;=&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;file:///dvddisc/ADV_OBJ/as_manifest.xmf&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;sync&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;=&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;hard&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;&amp;gt;&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: #a31515; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;Subtitle&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;description&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;=&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;"&lt;SPAN style="COLOR: blue"&gt;English Test&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;track&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;=&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;1&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;/&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: #a31515; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;ApplicationResource&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;priority&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;=&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;"&lt;SPAN style="COLOR: blue"&gt;1&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;size&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;=&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;99999&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;multiplexed&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;=&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;true&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;src&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;=&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;file:///dvddisc/ADV_OBJ/as_manifest.xmf&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;/&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: #a31515; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;ApplicationResource&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;priority&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;=&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;"&lt;SPAN style="COLOR: blue"&gt;1&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;size&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;=&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;99999&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;multiplexed&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;=&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;true&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;src&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;=&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;file:///dvddisc/ADV_OBJ/as_markup.xas&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;/&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: #a31515; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;ApplicationResource&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;priority&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;=&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;"&lt;SPAN style="COLOR: blue"&gt;1&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;size&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;=&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;99999&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;multiplexed&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;=&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;true&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;src&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;=&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;file:///dvddisc/ADV_OBJ/Miramo.ttf&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;/&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 6pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: #a31515; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;AdvancedSubtitleSegment&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/DIV&gt;
&lt;P&gt;&lt;STRONG&gt;Generating an Advanced Subtitle Markup Page&lt;BR&gt;&lt;/STRONG&gt;When generating subtitles, the primary information needed is the text being spoken, when it appears on screen, when it ends.&amp;nbsp; The simplicity and regular structure of this data lends itself nicely to automation, of which I am a big fan.&amp;nbsp; &lt;/P&gt;
&lt;P&gt;At the end of this project you will find a sample advanced subtitles project.&amp;nbsp; In this project is an Excel file with a macro that will generate an advanced subtitle markup page with the data entered on the first tab (Subtitles).&amp;nbsp; The default x and y positioning and alignment may be overridden by enter a new value in the override columns. &amp;nbsp;&amp;nbsp;Default values for your markup page are set on the second tab (Settings). &lt;/P&gt;
&lt;P&gt;When opening the Excel file, be sure to enable macros.&amp;nbsp; There is some low level of data checking.&amp;nbsp; For instance, entering a start or end value in the wrong format will turn the row red.&amp;nbsp; But, always be sure to run the validator on your project to make sure the output is correct.&amp;nbsp; And, once you're ready to export your markup file, press the "Export Subtitles" button at the top of the page, or press CTRL+r.&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=6460835" width="1" height="1"&gt;</description><enclosure url="http://blogs.msdn.com/amyd/attachment/6460835.ashx" length="169651" type="application/x-zip-compressed" /><category domain="http://blogs.msdn.com/amyd/archive/tags/HD+DVD/default.aspx">HD DVD</category><category domain="http://blogs.msdn.com/amyd/archive/tags/HDi/default.aspx">HDi</category><category domain="http://blogs.msdn.com/amyd/archive/tags/markup/default.aspx">markup</category><category domain="http://blogs.msdn.com/amyd/archive/tags/sample+code/default.aspx">sample code</category></item><item><title>Virtual Keyboards</title><link>http://blogs.msdn.com/amyd/archive/2007/10/24/virtual-keyboards.aspx</link><pubDate>Wed, 24 Oct 2007 10:33:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:5641659</guid><dc:creator>Amy</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/amyd/comments/5641659.aspx</comments><wfw:commentRss>http://blogs.msdn.com/amyd/commentrss.aspx?PostID=5641659</wfw:commentRss><description>&lt;P&gt;The input tag has four options for mode: password, singleline, multiline or display. When an input element with singleline, multiline, or password mode receives focus, the player &lt;EM&gt;&lt;STRONG&gt;may&lt;/STRONG&gt;&lt;/EM&gt; launch an onscreen keyboard to allow user input or a software player may enable use of the computer keyboard. This is not required, though (currently, only the Xbox presents the user with a keyboard). And, there's no guarantee on how a player's keyboard will look and if they will implement all the keys you want. Maybe you want an alphabetical keyboard. Maybe you want “.com” and “.net” keys to make entering email addresses easier. If you need user input, your best bet is to use the display mode on your input tag and implement your own virtual keyboard. &lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;IMG src="http://blogs.msdn.com/photos/hddvd/images/5641670/original.aspx" border=0&gt;&lt;/P&gt;
&lt;P&gt;&lt;BR&gt;The project at the end of this blog has 3 sample virtual keyboards to choose from - alphabetical (for me), &lt;A class="" href="http://en.wikipedia.org/wiki/Qwerty" target=_blank mce_href="http://en.wikipedia.org/wiki/Qwerty"&gt;QWERTY&lt;/A&gt;, and &lt;A class="" href="http://en.wikipedia.org/wiki/Dvorak_Simplified_Keyboard" target=_blank mce_href="http://en.wikipedia.org/wiki/Dvorak_Simplified_Keyboard"&gt;Dvorak&lt;/A&gt;&amp;nbsp;(for Chris).&amp;nbsp; They all use the same markup, styles, timing, and script files.&amp;nbsp; Only the markup files are different.&lt;/P&gt;
&lt;P mce_keep="true"&gt;Here's a sample of what the "A" key looks like:&lt;/P&gt;
&lt;DIV style="COLOR: #333333; BACKGROUND-COLOR: #ffffff"&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: #a31515; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;div&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;style&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;=&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;"&lt;SPAN style="COLOR: blue"&gt;key col1&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;class&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;=&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;uppercase&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;&amp;gt;&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: #a31515; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;button&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;class&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;=&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;"&lt;SPAN style="COLOR: blue"&gt;key btn&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;style&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;=&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;key_btn&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;accessKey&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;=&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;VK_A_BUTTON&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;custom:key&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;=&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;A&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;/&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: #a31515; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;p&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;A&lt;SPAN style="COLOR: blue"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: #a31515"&gt;p&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 6pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: #a31515; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;div&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/DIV&gt;
&lt;P&gt;&lt;B&gt;&lt;BR&gt;class&lt;BR&gt;&lt;/B&gt;The parent div has a class attribute.&amp;nbsp; A class is a way to group similar elements.&amp;nbsp; It doesn't apply a style like the same attribute would in HTML.&amp;nbsp; Class is used here to group which elements are hid or shown when the shift button is actioned.&amp;nbsp; Class is also used to group all the keyboard keys so only one cue is needed for all buttons with the class applied.&lt;/P&gt;
&lt;DIV style="COLOR: #333333; BACKGROUND-COLOR: #ffffff"&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: #a31515; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;cue&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;begin&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;=&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;"&lt;SPAN style="COLOR: blue"&gt;class('key')[state:actioned()]&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;end&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;=&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;defaultNode()[not(state:actioned())]&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: #a31515; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;event&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;name&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;=&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;"&lt;SPAN style="COLOR: blue"&gt;key_action&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;/&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 6pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: #a31515; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;cue&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/DIV&gt;
&lt;P&gt;&lt;B&gt;&lt;BR&gt;Custom Namespace&lt;BR&gt;&lt;/B&gt;The buttons of the keyboard also have a "custom:key" attribute.&amp;nbsp; The markup is extensible and custom attributes can be added if you add the namespace to the root element of the document.&lt;/P&gt;
&lt;DIV style="COLOR: #333333; BACKGROUND-COLOR: #ffffff"&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 6pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;xmlns:custom&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;=&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;"&lt;SPAN style="COLOR: blue"&gt;http://custom&lt;/SPAN&gt;"&lt;/SPAN&gt;&lt;/P&gt;&lt;/DIV&gt;
&lt;P&gt;This allows us to pass custom information on the button that has been actioned to the script by calling getNamedItem on the target of the action&lt;BR&gt;&lt;BR&gt;&lt;/P&gt;
&lt;DIV style="COLOR: #333333; BACKGROUND-COLOR: #ffffff"&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;var&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; element = evt.target;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;var&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; attr = element.attributes.getNamedItem(&lt;SPAN style="COLOR: #a31515"&gt;"custom:key"&lt;/SPAN&gt;);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;var&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; key = attr.value;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/DIV&gt;
&lt;P mce_keep="true"&gt;&lt;B&gt;&lt;BR&gt;accessKey&lt;BR&gt;&lt;/B&gt;Adding accessKey to a button adds a shortcut to actioning that button.&amp;nbsp; This is particularly useful for the number keys because it allows users to navigate the keyboard or use the number panel on the remote.&amp;nbsp; Note that for the letter keys, only keys A, B, C, and D are required to be supported.&amp;nbsp; Letters E-L are optionally supported.&amp;nbsp; Letters M-Z are not supported.&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;B&gt;&lt;BR&gt;computeImplicitNav&lt;BR&gt;&lt;/B&gt;As I stated earlier, shift is being handled by hiding or showing uppercase or lowercase classes.&amp;nbsp; By setting style:display to none, the disabled keys are removed from display.&amp;nbsp; However, changing a key's display from none to auto does not automatically add the element to the keyboard's navigation.&amp;nbsp; So, when display has been updated, an event is sent to the script and computeImplicitNav re-calculates the keyboard's implicit navigation. &lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=5641659" width="1" height="1"&gt;</description><enclosure url="http://blogs.msdn.com/amyd/attachment/5641659.ashx" length="71255" type="application/x-zip-compressed" /><category domain="http://blogs.msdn.com/amyd/archive/tags/HDi/default.aspx">HDi</category><category domain="http://blogs.msdn.com/amyd/archive/tags/script/default.aspx">script</category><category domain="http://blogs.msdn.com/amyd/archive/tags/markup/default.aspx">markup</category><category domain="http://blogs.msdn.com/amyd/archive/tags/simulator/default.aspx">simulator</category><category domain="http://blogs.msdn.com/amyd/archive/tags/sample+code/default.aspx">sample code</category></item><item><title>HD DVD Script Object Model</title><link>http://blogs.msdn.com/amyd/archive/2007/10/23/hd-dvd-script-object-model.aspx</link><pubDate>Wed, 24 Oct 2007 09:23:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:5642420</guid><dc:creator>Amy</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/amyd/comments/5642420.aspx</comments><wfw:commentRss>http://blogs.msdn.com/amyd/commentrss.aspx?PostID=5642420</wfw:commentRss><description>&lt;P&gt;Have you ever been working on an HDi project and needed to look up a method name in Annex Z, but you don't have it handy (or access at all)?&amp;nbsp; Well, luckily the &lt;A class="" href="http://www.microsoft.com/downloads/details.aspx?FamilyId=F8ADA3F5-0EC6-4392-84AB-CB4860DB30ED&amp;amp;displaylang=en" target=_blank mce_href="http://www.microsoft.com/downloads/details.aspx?FamilyId=F8ADA3F5-0EC6-4392-84AB-CB4860DB30ED&amp;amp;displaylang=en"&gt;Interactivity Jumpstart Kit&lt;/A&gt; ships with the HD DVD Script Object Model as a Visio file and a PNG.&amp;nbsp; You'll find this very useful file in C:\Program Files\HD DVD Interactivity Jumpstart\Documentation.&lt;/P&gt;
&lt;P&gt;And, while you're in there, check out the CHM file.&amp;nbsp; It has all the command line options for the simulator and the validator, keyboard mappings, and information on how to use the CreateACA and CreateDiscID tools.&lt;/P&gt;
&lt;P&gt;Good stuff.&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=5642420" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/amyd/archive/tags/HDi/default.aspx">HDi</category><category domain="http://blogs.msdn.com/amyd/archive/tags/script/default.aspx">script</category><category domain="http://blogs.msdn.com/amyd/archive/tags/simulator/default.aspx">simulator</category></item><item><title>Dynamic Content</title><link>http://blogs.msdn.com/amyd/archive/2007/10/18/dynamic-content.aspx</link><pubDate>Thu, 18 Oct 2007 19:01:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:5498354</guid><dc:creator>Amy</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/amyd/comments/5498354.aspx</comments><wfw:commentRss>http://blogs.msdn.com/amyd/commentrss.aspx?PostID=5498354</wfw:commentRss><description>&lt;P mce_keep="true"&gt;Today's sample was created upon a request from my&amp;nbsp;very nice&amp;nbsp;and hard working office-mate Chris.&amp;nbsp; Last week Chris began learning HDi.&amp;nbsp; He whizzed through all the Jumpstart samples and the projects on my blog, and jumped into creating a project that would dynamically generate content on the fly.&amp;nbsp; After messing around with his project for a few days, Chris said I should write a blog how to do this for other people who had questions like his.&amp;nbsp; So, here it is.&amp;nbsp; &lt;/P&gt;
&lt;P&gt;There is a sample project is attached at the end of this blog.&amp;nbsp; In this project, an XML file is parsed, data is extracted using XPath, text is dynamically added to the markup, and new "skins" are applied to the data by changing the loaded markup file.&lt;/P&gt;
&lt;P&gt;&lt;B&gt;&lt;BR&gt;XML Data&lt;BR&gt;&lt;/B&gt;Let's say you have a project where you want to separate your data from your presentation layer.&amp;nbsp; Maybe you want to download new content from the network.&amp;nbsp; Maybe you want to be able to apply different skins to the same piece of content.&amp;nbsp; The obvious way to separate your data is by using XML.&amp;nbsp; &lt;/P&gt;
&lt;DIV style="COLOR: #333333; BACKGROUND-COLOR: #ffffff"&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&amp;lt;?&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: #a31515; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;xml&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;version&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;=&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;"&lt;SPAN style="COLOR: blue"&gt;1.0&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;encoding&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;=&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;utf-8&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;?&amp;gt;&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: #a31515; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;data&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: #a31515; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;headline&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;value&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;=&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;"&lt;SPAN style="COLOR: blue"&gt;This Is The Header&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;/&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: #a31515; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;subheading&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: red; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;value&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;=&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;"&lt;SPAN style="COLOR: blue"&gt;Here's a Subheading&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;/&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: #a31515; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;paragraph&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;Lorem ipsum . . .&lt;SPAN style="COLOR: blue"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: #a31515"&gt;paragraph&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: #a31515; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;paragraph&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;Lorem ipsum . . .&lt;SPAN style="COLOR: blue"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: #a31515"&gt;paragraph&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 6pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: #a31515; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;data&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/DIV&gt;
&lt;P&gt;In this project, the data is in a file called data.xml and it is included with the project.&lt;/P&gt;
&lt;P&gt;&lt;B&gt;&lt;BR&gt;XMLParser&lt;BR&gt;&lt;/B&gt;Before the application does anything with this XML, we need to use the XMLParser to create a DOM.&lt;BR&gt;&lt;BR&gt;&lt;BR&gt;&lt;/P&gt;
&lt;DIV style="COLOR: #333333; BACKGROUND-COLOR: #ffffff"&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 6pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;XMLParser.parse(&lt;SPAN style="COLOR: #a31515"&gt;uri&lt;/SPAN&gt;, parseCallback);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 6pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;function &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;parseCallback(status, dom)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 6pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; TEXT-INDENT: 0.5in; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;if&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; (status == XMLParser.OK)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 6pt; TEXT-INDENT: 0.5in"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 6pt 0.5in; TEXT-INDENT: 0.5in"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: green; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;//do something with dom&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 6pt; TEXT-INDENT: 0.5in"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 6pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/DIV&gt;
&lt;P&gt;&lt;BR&gt;XMLParser.parse takes two arguments - uri is the full path of the xml file (file:///dvddisc/ADV_OBJ/data.xml in this project) and the callback function which is called when the XMLParser has completed and is ready to return the DOM.&lt;/P&gt;
&lt;P&gt;XMLParser also has a method called parseString which will create a DOM from a string.&amp;nbsp; The parseString function returns the DOM directly without the callback.&lt;BR&gt;&lt;BR&gt;&lt;BR&gt;&lt;/P&gt;
&lt;DIV style="COLOR: #333333; BACKGROUND-COLOR: #ffffff"&gt;
&lt;P&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"&gt;var dom = &lt;SPAN style="mso-no-proof: yes"&gt;XMLParser.parseString(&lt;SPAN style="COLOR: #a31515"&gt;&lt;FONT color=#333333&gt;"&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #a31515"&gt;data&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;&amp;gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #a31515"&gt;headline&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;value&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;=\&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;This Is The Header\&lt;/SPAN&gt;"&lt;SPAN style="COLOR: blue"&gt;/&amp;gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: #a31515"&gt;data&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;&amp;gt;&lt;/SPAN&gt;&lt;FONT color=#333333&gt;&lt;SPAN style="COLOR: #a31515"&gt;"&lt;/SPAN&gt;);&lt;BR&gt;&lt;SPAN style="COLOR: blue"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/DIV&gt;
&lt;P&gt;&lt;BR&gt;This can be very handy to use if your XML comes from getResponseString() from a network request or if you want to create a new empty DOM on the fly. (For more information on networking, read &lt;A href="http://blogs.msdn.com/amyd/archive/2007/09/20/very-simple-network-example.aspx"&gt;http://blogs.msdn.com/amyd/archive/2007/09/20/very-simple-network-example.aspx&lt;/A&gt;)&lt;BR&gt;&lt;BR&gt;&lt;B&gt;&lt;BR&gt;evaluateXPath&lt;BR&gt;&lt;/B&gt;There are a couple of ways to can go through the newly created DOM.&amp;nbsp; We could cycle through all the childNodes using DOM Level 2 &lt;A class="" href="http://www.w3.org/TR/DOM-Level-2-Core/ecma-script-binding.html" target=_blank mce_href="http://www.w3.org/TR/DOM-Level-2-Core/ecma-script-binding.html"&gt;ECMAScript Language Binding&lt;/A&gt;.&amp;nbsp; Or, we can use XPath.&amp;nbsp; (Note, Xpath &lt;A class="" href="http://www.w3.org/TR/xpath#axes" target=_blank mce_href="http://www.w3.org/TR/xpath#axes"&gt;axes&lt;/A&gt; are not supported).&amp;nbsp; In this project, I've chosen to use some simple XPath calls to extract my data using evaluateXPath.&lt;BR&gt;&lt;BR&gt;&lt;BR&gt;&lt;/P&gt;
&lt;DIV style="COLOR: #333333; BACKGROUND-COLOR: #ffffff"&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 6pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;var&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; nodes = dom.evaluateXPath(&lt;SPAN style="COLOR: #a31515"&gt;"//headline"&lt;/SPAN&gt;, dom.documentElement);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/DIV&gt;
&lt;P&gt;&lt;BR&gt;evaluateXPath returns a &lt;A class="" href="http://blogs.msdn.com/ptorr/archive/2006/11/07/live-vs-loaded-dom.aspx" target=_blank mce_href="http://blogs.msdn.com/ptorr/archive/2006/11/07/live-vs-loaded-dom.aspx"&gt;nodeList&lt;/A&gt;.&amp;nbsp; Since I know I'm only expecting one headline here, if I do get a non-empty nodelist, I only need the first item and its value attribute.&lt;BR&gt;&lt;BR&gt;&lt;BR&gt;&lt;/P&gt;
&lt;DIV style="COLOR: #333333; BACKGROUND-COLOR: #ffffff"&gt;
&lt;P&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;var&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; headline = nodes.item(0).getAttribute(&lt;SPAN style="COLOR: #a31515"&gt;"value"&lt;/SPAN&gt;);&lt;/SPAN&gt;&lt;/P&gt;&lt;/DIV&gt;
&lt;P&gt;&lt;BR&gt;The call to evaluteXPath for paragraph from my DOM will return more than one node.&amp;nbsp; Also, the data here is in a text node, not an attribute.&amp;nbsp; This text node is the first child of the paragraph tag and its contents can be retrieved by calling nodeValue.&lt;BR&gt;&lt;BR&gt;&lt;BR&gt;&lt;/P&gt;
&lt;DIV style="COLOR: #333333; BACKGROUND-COLOR: #ffffff"&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;for&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; (&lt;SPAN style="COLOR: blue"&gt;var&lt;/SPAN&gt; i = 0; i &amp;lt; nodes.length; i++)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: green"&gt;// do something with nodes.item(i).firstChild.nodeValue;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 6pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;}&lt;/SPAN&gt;&lt;/P&gt;&lt;/DIV&gt;
&lt;P&gt;&lt;BR&gt;I could go back to this DOM every time I need to get this data, but my application would take a performance hit.&amp;nbsp; So once I get my data, I cache it for use later.&lt;/P&gt;
&lt;P&gt;&lt;B&gt;&lt;BR&gt;Adding Text to Markup&lt;/B&gt;&lt;/P&gt;
&lt;P&gt;Okay, the XML has been parsed and data cached, so now we can put it in the markup.&amp;nbsp; Here we will use the DOM Level 2 &lt;A class="" href="http://www.w3.org/TR/DOM-Level-2-Core/ecma-script-binding.html" target=_blank mce_href="http://www.w3.org/TR/DOM-Level-2-Core/ecma-script-binding.html"&gt;ECMAScript Language Binding&lt;/A&gt; to create new paragraph tags (elements that can hold text) and text nodes inside.&lt;BR&gt;&lt;BR&gt;&lt;BR&gt;&lt;/P&gt;
&lt;DIV style="COLOR: #333333; BACKGROUND-COLOR: #ffffff"&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;function&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; addText(element, txt) &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;var&lt;/SPAN&gt; p = document.createElement(&lt;SPAN style="COLOR: #a31515"&gt;"p"&lt;/SPAN&gt;);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;var&lt;/SPAN&gt; text = document.createTextNode(txt);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;p.appendChild(text);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;element.appendChild(p);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/DIV&gt;
&lt;P&gt;&lt;BR&gt;And, of course once this is complete, we load the changes to the modified markup by calling document.load.&amp;nbsp; For more information on why you need to call document.load, read Peter Torr's blog on &lt;A class="" href="http://blogs.msdn.com/ptorr/archive/2006/11/07/live-vs-loaded-dom.aspx" target=_blank mce_href="http://blogs.msdn.com/ptorr/archive/2006/11/07/live-vs-loaded-dom.aspx"&gt;Live vs. Load DOM&lt;/A&gt;.&lt;/P&gt;
&lt;P&gt;&lt;B&gt;&lt;BR&gt;Switching Between Markup Files&lt;BR&gt;&lt;/B&gt;And, finally, just for kicks, I've added the ability to load new markup pages in order to reskin the data using the link() function.&lt;BR&gt;&lt;BR&gt;&lt;/P&gt;
&lt;P&gt;Happy Programming!&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=5498354" width="1" height="1"&gt;</description><enclosure url="http://blogs.msdn.com/amyd/attachment/5498354.ashx" length="67258" type="application/x-zip-compressed" /><category domain="http://blogs.msdn.com/amyd/archive/tags/HDi/default.aspx">HDi</category><category domain="http://blogs.msdn.com/amyd/archive/tags/script/default.aspx">script</category><category domain="http://blogs.msdn.com/amyd/archive/tags/markup/default.aspx">markup</category><category domain="http://blogs.msdn.com/amyd/archive/tags/simulator/default.aspx">simulator</category><category domain="http://blogs.msdn.com/amyd/archive/tags/sample+code/default.aspx">sample code</category></item><item><title>Saving Resume Information, part II</title><link>http://blogs.msdn.com/amyd/archive/2007/09/24/save-resume-information-part-ii.aspx</link><pubDate>Tue, 25 Sep 2007 01:15:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:4849405</guid><dc:creator>Amy</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/amyd/comments/4849405.aspx</comments><wfw:commentRss>http://blogs.msdn.com/amyd/commentrss.aspx?PostID=4849405</wfw:commentRss><description>&lt;P&gt;In&amp;nbsp;&lt;A class="" href="http://blogs.msdn.com/amyd/archive/2007/08/19/saving-resume-information.aspx" mce_href="http://blogs.msdn.com/amyd/archive/2007/08/19/saving-resume-information.aspx"&gt;a previous post&lt;/A&gt;, I stated that when you press the stop button on your player, you have 2 seconds to continue to execute code before the player shuts down.&amp;nbsp; But, that statement needs to be qualified.&amp;nbsp; If you try to&amp;nbsp;delay the application_end (or the deprecated stop_request) event by calling preventDefault &lt;STRONG&gt;when the user has pressed the stop, eject, or power button,&lt;/STRONG&gt; &lt;STRONG&gt;the player will stop&amp;nbsp;permitting preventDefault&amp;nbsp;after two seconds&lt;/STRONG&gt;.&amp;nbsp; If you do not call preventDefault, you have a single tick to execute your code.&amp;nbsp; This means that the function that handles the application_end event will be called, but not any callbacks that would have been handled in subsequent ticks.&amp;nbsp; This is why using setContentInformation works, but trying to write your own XML file will not execute to completion.&lt;/P&gt;
&lt;P&gt;However, if you just add a call to preventDefault to the event handler, and the application_end is actually triggered by the title&amp;nbsp;end (and not the user pressing stop), you will end up creating an infitite loop.&amp;nbsp; So, if you want to use preventDefault to allow more execution time, make sure to include an exit point in your script so that the application can end when your script is complete.&lt;/P&gt;
&lt;P&gt;Below is an example of how &lt;A class="" href="http://blogs.msdn.com/amyd/archive/2007/08/19/saving-resume-information.aspx" mce_href="http://blogs.msdn.com/amyd/archive/2007/08/19/saving-resume-information.aspx"&gt;the previous project&lt;/A&gt; would be modified if you were to call preventDefault on the&amp;nbsp;application_end event:&lt;/P&gt;
&lt;DIV style="FONT-FAMILY: courier"&gt;
&lt;P&gt;addEventListener("application_end", handleApplicationEnd, false);&lt;/P&gt;
&lt;P&gt;/******************************&lt;BR&gt;&amp;nbsp; BEGIN ADDED CODE&lt;BR&gt;********************************/&lt;BR&gt;//end sequence status&lt;BR&gt;var endSeq = {&lt;BR&gt;&amp;nbsp; initialized:false,&lt;BR&gt;&amp;nbsp; complete:false&lt;BR&gt;};&lt;BR&gt;/******************************&lt;BR&gt;&amp;nbsp; END ADDED CODE&lt;BR&gt;********************************/&lt;/P&gt;
&lt;P&gt;function setResume( time ) &lt;BR&gt;{&amp;nbsp; &lt;BR&gt;&amp;nbsp; try &lt;BR&gt;&amp;nbsp; {&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; //set key for resume time&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; psd.setContentInformation(contentID, resumeKey, time, setContentInfoCB);&lt;BR&gt;&amp;nbsp; } &lt;BR&gt;&amp;nbsp; catch(ex)&lt;BR&gt;&amp;nbsp; { &lt;BR&gt;/******************************&lt;BR&gt;&amp;nbsp; BEGIN ADDED CODE&lt;BR&gt;********************************/&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; //set end sequence to complete&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; endSeq.complete = true; &lt;BR&gt;/******************************&lt;BR&gt;&amp;nbsp; END ADDED CODE&lt;BR&gt;********************************/&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; TraceError("EXCEPTION on setContentInformation", ex, arguments.callee);&lt;BR&gt;&amp;nbsp; }&lt;BR&gt;&amp;nbsp; &lt;BR&gt;&amp;nbsp; function setContentInfoCB( result, key )&lt;BR&gt;&amp;nbsp; { &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; if ( result == PersistentStorageManager.SUCCEEDED ) &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; TraceInfo("SUCCEEDED on setContentInformation", arguments.callee);&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; else &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; TraceInfo("FAILED on setContentInformation", arguments.callee);&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;BR&gt;/******************************&lt;BR&gt;&amp;nbsp; BEGIN ADDED CODE&lt;BR&gt;********************************/&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; //set end sequence to complete&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; endSeq.complete = true;&amp;nbsp;&amp;nbsp; &lt;BR&gt;/******************************&lt;BR&gt;&amp;nbsp; END ADDED CODE&lt;BR&gt;********************************/&lt;BR&gt;&amp;nbsp; }&lt;BR&gt;}&lt;/P&gt;
&lt;P&gt;function handleApplicationEnd(evt)&lt;BR&gt;{&lt;/P&gt;
&lt;P&gt;/******************************&lt;BR&gt;&amp;nbsp; BEGIN ADDED CODE&lt;BR&gt;********************************/&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; //end sequence complete, exit&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (endSeq.complete) return;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; //prevent end for another tick&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; evt.preventDefault();&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; //end sequence initialized, exit&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (endSeq.initialized) return;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; endSeq.initialized = true;&lt;BR&gt;/******************************&lt;BR&gt;&amp;nbsp; END ADDED CODE&lt;BR&gt;********************************/&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; //event should pass value time based on title timeline&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; //if not, use elapsedTime&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; //this value could be equal to or greater than the movie runtime,&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; //check for this before using value in resume&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; var time = evt.time &amp;amp;&amp;amp; (evt.time).match(timeCodeRegEx) ? evt.time : Player.playlist.currentTitle.elapsedTime;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; setResume(time);&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;BR&gt;}&lt;/P&gt;&lt;/DIV&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=4849405" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/amyd/archive/tags/HD+DVD/default.aspx">HD DVD</category><category domain="http://blogs.msdn.com/amyd/archive/tags/HDi/default.aspx">HDi</category><category domain="http://blogs.msdn.com/amyd/archive/tags/script/default.aspx">script</category></item><item><title>Very Simple Network Example</title><link>http://blogs.msdn.com/amyd/archive/2007/09/20/very-simple-network-example.aspx</link><pubDate>Fri, 21 Sep 2007 02:36:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:5022412</guid><dc:creator>Amy</dc:creator><slash:comments>1</slash:comments><comments>http://blogs.msdn.com/amyd/comments/5022412.aspx</comments><wfw:commentRss>http://blogs.msdn.com/amyd/commentrss.aspx?PostID=5022412</wfw:commentRss><description>&lt;P mce_keep="true"&gt;I have&amp;nbsp;received a couple requests for an example of networking, so I put something very basic together to show some simple functionality.&amp;nbsp; &lt;/P&gt;
&lt;P&gt;What it does have:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Functionality to download a file from a server to persistent storage&lt;/LI&gt;
&lt;LI&gt;Calculation of percentage of download complete&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;What it does not have:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Server component - This will work in a development environment, but not elsewhere. You will still need to take care of AACS encapsulation and server certificates for this to function in the real world&lt;/LI&gt;
&lt;LI&gt;Management of connections - You may have up to 8 active HTTP clients at one time. This&amp;nbsp;script does not check for that&lt;/LI&gt;
&lt;LI&gt;P-storage storage capacity check - I am assuming there is sufficient space in persistent storage to download this file. That is a bad real world assumption.&lt;/LI&gt;
&lt;LI&gt;Parsing of XML from a server - Your initial server communication will most likely be to request an XML string that describes the downloads available. This XML should also contain the file size of your downloads so you can check p-storage for capacity and show download progress&lt;/LI&gt;
&lt;LI&gt;Lots of other important features like using headers, using other request methods, sending files to a server, dynamically generating a timeout value, handling failed downloads when not using a timeout, etc.&lt;/LI&gt;&lt;/UL&gt;
&lt;DIV style="COLOR: #333333; BACKGROUND-COLOR: #ffffff"&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: green; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;//location of file to be downloaded&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: green; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;//the real URL should be a valid domain&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;var&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; src = &lt;SPAN style="COLOR: #a31515"&gt;"http://localhost/sample_file.txt"&lt;/SPAN&gt;;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: green; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;//destination where download will be stored&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: green; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;//here its the same file name as the downloaded file, stored in p-storage&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;var&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; dest = &lt;SPAN style="COLOR: #a31515"&gt;"file:///required/"&lt;/SPAN&gt; + PersistentStorageManager.contentId + src.substring(src.lastIndexOf(&lt;SPAN style="COLOR: #a31515"&gt;"/"&lt;/SPAN&gt;),src.length);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: green; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;//timeout in seconds...use -1 for no timeout&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;var&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; timeout = 30;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: green; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;//size of download - use for percent download complete&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;var&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; downloadSize = 5000;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: green; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;//network object - referenced in OnDownloadStateChange&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;var&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; httpClient;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: green; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;//confirm user has network connection&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;if&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; (Player.capabilities.network.connected == &lt;SPAN style="COLOR: blue"&gt;true&lt;/SPAN&gt;) &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;try&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;{ &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;httpClient = Network.createHTTPClient(src, Network.HTTP_GET, timeout);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;httpClient.downloadFileLocation = dest;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: green"&gt;//set a callback to track progress of download&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;httpClient.onStateChange = OnDownloadStateChange;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;httpClient.send();&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;catch&lt;/SPAN&gt;(ex)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;TraceError(&lt;SPAN style="COLOR: #a31515"&gt;"Download FAILED"&lt;/SPAN&gt;, ex, arguments.callee);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;else&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;TraceInfo(&lt;SPAN style="COLOR: #a31515"&gt;"Network connection not available"&lt;/SPAN&gt;,arguments.callee);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;function&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt; OnDownloadStateChange(state)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;{&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;switch&lt;/SPAN&gt; (state) &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;case&lt;/SPAN&gt; httpClient.STATE_RESPONSEPROGRESS:&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: green"&gt;/*&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: green; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;Download is still occuring&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: green; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;If you know your download size, you can look at&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: green; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;httpClient.dataDownloaded to determine percent progress&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: green; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;*/&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;if&lt;/SPAN&gt; (downloadSize) &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;var&lt;/SPAN&gt; percentComplete = Math.floor(100 * httpClient.dataDownloaded / downloadSize);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;break&lt;/SPAN&gt;;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;case&lt;/SPAN&gt; httpClient.STATE_COMPLETED:&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: green"&gt;/*&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: green; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;Do something with file that is now at downloadLocation&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: green; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;*/&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;TraceInfo(&lt;SPAN style="COLOR: #a31515"&gt;"STATE_COMPLETED"&lt;/SPAN&gt;,arguments.callee);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;httpClient = &lt;SPAN style="COLOR: blue"&gt;null&lt;/SPAN&gt;; &lt;SPAN style="COLOR: green"&gt;//destroy client to avoid closure issue&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;break&lt;/SPAN&gt;;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;case&lt;/SPAN&gt; httpClient.STATE_ERROR:&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: green"&gt;/*&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: green; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;Download failed, handle accordingly&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: green; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;*/&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;TraceInfo(&lt;SPAN style="COLOR: #a31515"&gt;"STATE_ERROR"&lt;/SPAN&gt;,arguments.callee);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;httpClient = &lt;SPAN style="COLOR: blue"&gt;null&lt;/SPAN&gt;; &lt;SPAN style="COLOR: green"&gt;//destroy client to avoid closure issue&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;break&lt;/SPAN&gt;;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;case&lt;/SPAN&gt; httpClient.STATE_ABORT:&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: green"&gt;/*&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: green; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;Download aborted, handle accordingly&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: green; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;*/&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;TraceInfo(&lt;SPAN style="COLOR: #a31515"&gt;"STATE_ABORT"&lt;/SPAN&gt;,arguments.callee);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;httpClient = &lt;SPAN style="COLOR: blue"&gt;null&lt;/SPAN&gt;; &lt;SPAN style="COLOR: green"&gt;//destroy client to avoid closure issue&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;break&lt;/SPAN&gt;;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;}&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'; mso-no-proof: yes"&gt;&lt;/SPAN&gt;&amp;nbsp;&lt;/P&gt;&lt;/DIV&gt;
&lt;P&gt;&lt;EM&gt;UPDATE:&amp;nbsp;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;Or, alternatively if you are only expecting a&amp;nbsp;text string as a response from the server,&amp;nbsp;don't set downloadFileLocation and on STATE_COMPLETED,&amp;nbsp;use httpClient.getResponseString() to get that text string&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=5022412" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/amyd/archive/tags/HD+DVD/default.aspx">HD DVD</category><category domain="http://blogs.msdn.com/amyd/archive/tags/HDi/default.aspx">HDi</category><category domain="http://blogs.msdn.com/amyd/archive/tags/script/default.aspx">script</category></item><item><title>Saving Resume Information</title><link>http://blogs.msdn.com/amyd/archive/2007/08/19/saving-resume-information.aspx</link><pubDate>Mon, 20 Aug 2007 04:20:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:4471015</guid><dc:creator>Amy</dc:creator><slash:comments>1</slash:comments><comments>http://blogs.msdn.com/amyd/comments/4471015.aspx</comments><wfw:commentRss>http://blogs.msdn.com/amyd/commentrss.aspx?PostID=4471015</wfw:commentRss><description>&lt;P&gt;If you've purchased a DVD player in the last few years or used a software player, likely you've experienced a built in player feature that remembers where you last left off in the movie and allows you to resume play from that point.&amp;nbsp; That functionality is player dependent - and usually the memory is discarded when you eject the disc. Because HD DVD has persistent storage, you can add this resume playback feature to your disc so that the user experience will be consistent from player to player - even if the user ejects the disc before resuming playback at another time. &lt;/P&gt;
&lt;P&gt;To determine when the user has stopped playback on the disc, you should listen for the application_end event.&amp;nbsp; Once this event fires, you have approximately 2 seconds to capture the necessary information and save it before the player shuts down.&amp;nbsp; This is plenty of time to capture the elapsed time of the current title and set a key in the content's info.txt file.&lt;/P&gt;
&lt;P&gt;The code to do this is simple and straight forward:&lt;/P&gt;
&lt;P style="FONT-FAMILY: courier"&gt;function handleApplicationEnd(evt)&lt;BR&gt;{&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; var pstoreDevices = PersistentStorageManager.getPersistentStorageDevices(PersistentStorageManager.STORAGE_REQUIRED);&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; var psd = pstoreDevices[0];&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; psd.setContentInformation(PersistentStorageManager.contentId, "resume", Player.playlist.currentTitle.elapsedTime, function(result, key){});&lt;BR&gt;}&lt;BR&gt;addEventListener("application_end", handleApplicationEnd, false);&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;BR&gt;Then, next time your discs plays, call getContentInformation on that key you just set to obtain your restart point.&amp;nbsp; &lt;/P&gt;
&lt;P&gt;In the attached project, the resume application runs as a title app.&amp;nbsp; When leaving a title (either by jumping or stopping the player), the application_end event will fire and a key related to the title id will be saved with the title's resume information.&amp;nbsp; On return to the title, if valid resume information is saved, the user will be asked if they wish to resume from the point they left off. &amp;nbsp;If the resume time is greater than or equal to the title duration, the user will not be prompted and the title will start from the beginning.&lt;/P&gt;
&lt;P&gt;&lt;I&gt;Note that the simulator does not fire the application_end event when you shut it down.&amp;nbsp; So, if you want to test this on the simulator, while the title with the application is playing, press CTRL+F to jump to the next title in the playlist which will trigger application_end.&lt;/I&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=4471015" width="1" height="1"&gt;</description><enclosure url="http://blogs.msdn.com/amyd/attachment/4471015.ashx" length="63099" type="application/x-zip-compressed" /><category domain="http://blogs.msdn.com/amyd/archive/tags/HD+DVD/default.aspx">HD DVD</category><category domain="http://blogs.msdn.com/amyd/archive/tags/HDi/default.aspx">HDi</category><category domain="http://blogs.msdn.com/amyd/archive/tags/script/default.aspx">script</category><category domain="http://blogs.msdn.com/amyd/archive/tags/sample+code/default.aspx">sample code</category></item><item><title>Persistent Storage Management</title><link>http://blogs.msdn.com/amyd/archive/2007/08/15/persistent-storage-management.aspx</link><pubDate>Thu, 16 Aug 2007 00:16:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:4405064</guid><dc:creator>Amy</dc:creator><slash:comments>1</slash:comments><comments>http://blogs.msdn.com/amyd/comments/4405064.aspx</comments><wfw:commentRss>http://blogs.msdn.com/amyd/commentrss.aspx?PostID=4405064</wfw:commentRss><description>&lt;P&gt;&lt;B&gt;&lt;/B&gt;&lt;/P&gt;
&lt;P&gt;One of the great features mandatory on every HD DVD player is at least 128 MB of persistent storage.&amp;nbsp; Many discs on the market are taking advantage of this feature to allow you to do things like save bookmarked scenes, download new trailers, or cache your login information to access network enabled content.&lt;/P&gt;
&lt;P&gt;The players do have a persistent storage management interface that will allow users to delete this saved content if the user so chooses.&amp;nbsp; However, the player's persistent storage management menu only allows the user to delete ALL the content for a disc.&amp;nbsp; So, it is &lt;B&gt;HIGHLY RECOMMENDED&lt;/B&gt; that if you are using persistent storage for your disc, that you...&lt;/P&gt;
&lt;OL&gt;
&lt;LI&gt;Provide your users with the ability to modify the contents saved on persistent storage for your disc from outside the player's persistent storage management menu. For instance, if your disc allows for the downloading trailers, make sure you also provide your user with the ability to delete these trailers from persistent storage via an application on the disc.&lt;BR&gt;&lt;/LI&gt;
&lt;LI&gt;
&lt;DIV mce_keep="true"&gt;Label your content and provider folders by setting a &lt;EM&gt;[language]-explanation&lt;/EM&gt; and/or &lt;EM&gt;[language]-icon&lt;/EM&gt; key as specified in chapter 10 of the DVD Specification for High Definition Video. (sample code and downloadable sample application provided below). When a user does use the player's persistent storage management menu, your disc's folder will be appropriately labeled and the user can avoid confusing it with another disc and accidentally deleting it.&lt;/DIV&gt;&lt;/LI&gt;&lt;/OL&gt;
&lt;P&gt;&lt;B&gt;&lt;BR&gt;Launching the Persistent Storage Management Menu&lt;/B&gt;&lt;/P&gt;
&lt;P&gt;To access the player's persistent storage management menu on a Toshiba player:&lt;/P&gt;
&lt;OL&gt;
&lt;LI&gt;Press "SETUP" on the remote. &lt;/LI&gt;
&lt;LI&gt;From the Setup menu, navigate to General &amp;gt; Maintenance &amp;gt; Persistent Storage&lt;/LI&gt;
&lt;LI&gt;Press "SETUP" on the remote again to launch the Persistent Storage Management Menu&lt;/LI&gt;&lt;/OL&gt;
&lt;P&gt;To access the player's persistent storage management menu on the Xbox:&lt;/P&gt;
&lt;OL&gt;
&lt;LI&gt;Launch the Xbox dashboard&lt;/LI&gt;
&lt;LI&gt;Navigate to the System blade&lt;/LI&gt;
&lt;LI&gt;Select Memory&lt;/LI&gt;
&lt;LI&gt;Choose HD DVD&lt;/LI&gt;&lt;/OL&gt;
&lt;P&gt;There is a good possibility that you will see several folders labeled "Unknown Provider" and "Unknown Content".&amp;nbsp; When a disc saves content to persistent storage, a unique folder is created based on that disc's content ID and nested under a folder based on its provider ID. The content and provider IDs are set in the DISCID.DAT file on the disc.&amp;nbsp; If a disc sets the &lt;EM&gt;[language]-explanation&lt;/EM&gt; and/or &lt;EM&gt;[language]-icon&lt;/EM&gt; keys, the user will be provided with meaningful labels.&amp;nbsp; If the disc does not set these keys, the specification states that the player should use "Unknown Provider" and "Unknown Content" as a label.&amp;nbsp; As you can probably imagine or even see for yourself - it quickly becomes difficult to distinguish between your content and provider folders if you do not set these keys.&lt;/P&gt;
&lt;P&gt;&lt;B&gt;&lt;BR&gt;Creating Labels for the Content and Provider Directories&lt;/B&gt;&lt;/P&gt;
&lt;P&gt;The simplest way to create a label for your content and provider directories is to set the &lt;EM&gt;[language]-explanation&lt;/EM&gt; keys for these directories to a string that describes your disc title and studio.&amp;nbsp; The value selected by the persistent storage management menu is determined by the user's menu language. So, if you only set the content folder's &lt;I&gt;en-explanation&lt;/I&gt; key and the user's menu language is set to Spanish (es), the user will still see "Unknown Content".&amp;nbsp; Thus, you will want to specify several languages in order to cover your anticipated audience.&lt;/P&gt;
&lt;P&gt;To set the key for your content directory, on the PersistentStorageDevice object for your required persistent storage, you would call&lt;/P&gt;
&lt;P&gt;setContentInformation(PersistentStorageManager.contentId, "en-explanation", "Title of My Movie", contentCallbackFunction)&lt;/P&gt;
&lt;P&gt;where contentCallbackFunction is the callback function that handles the result from your call.&lt;/P&gt;
&lt;P&gt;And, similarly, to set the key for your provider directory, on the PersistentStorageDevice object for your required persistent storage, you would call&lt;/P&gt;
&lt;P&gt;setProviderInformation("en-explanation", "Title of Movie Studio", providerCallbackFunction)&lt;/P&gt;
&lt;P&gt;where providerCallbackFunction is the callback function that handles the result from your call.&lt;/P&gt;
&lt;P&gt;But, as I stated earlier, you will want to set this key for multiple languages.&amp;nbsp; And, as you noticed, these functions have a callback and thus operate asynchronously.&amp;nbsp; So, to set multiple language keys without stepping on a previous call, you will need to wait for the callback from the previous call before calling the function a second time.&lt;/P&gt;
&lt;P&gt;The code to do this for the provider folder looks something like:&lt;/P&gt;
&lt;DIV style="FONT-FAMILY: courier"&gt;
&lt;P&gt;function setProviderLabel(providerInfo, languages)&lt;BR&gt;{&lt;BR&gt;&amp;nbsp;&amp;nbsp;//get reference to required p-storage devices&lt;BR&gt;&amp;nbsp; var pstoreDevices = PersistentStorageManager.getPersistentStorageDevices(PersistentStorageManager.STORAGE_REQUIRED);&lt;BR&gt;&amp;nbsp; var psd = pstoreDevices[0];&lt;BR&gt;&amp;nbsp; var provider_index = 0;&lt;/P&gt;
&lt;P&gt;&amp;nbsp; function setProviderExplanation( ) &lt;BR&gt;&amp;nbsp; {&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; psd.setProviderInformation( languages[ provider_index ] + "-explanation", providerInfo, setProviderExCB);&lt;BR&gt;&amp;nbsp; }&lt;BR&gt;&lt;BR&gt;&amp;nbsp; function setProviderExCB( result, key ) &lt;BR&gt;&amp;nbsp; {&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (result == PersistentStorageManager.SUCCEEDED &amp;amp;&amp;amp; provider_index &amp;lt; languages.length - 1) &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; //interate through languages&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; provider_index++;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; setProviderExplanation();&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;BR&gt;&amp;nbsp; }&lt;BR&gt;}&lt;/P&gt;
&lt;P&gt;setProviderLabel("Title of Movie Studio", ["en","es","fr"]);&lt;/P&gt;&lt;/DIV&gt;
&lt;P&gt;At the end of this post is a sample application which sets the &lt;EM&gt;[language]-explanation&lt;/EM&gt; keys for both provider and content using a function called setPStorLabel which takes your content description(s), provider description(s), and array of languages as arguments.&amp;nbsp; Including this script in your project will allow you to specify the labels for your provider and content folders in a single call:&lt;/P&gt;
&lt;P style="FONT-FAMILY: courier"&gt;setPStorLabel("Title of My Movie", "My Movie Studio", ["en","es","fr"]);&lt;/P&gt;
&lt;P&gt;&lt;B&gt;&lt;BR&gt;A Note About [language]-icon&lt;/B&gt;&lt;/P&gt;
&lt;P&gt;10.8 in the spec states that you may also set the &lt;EM&gt;[language]-icon&lt;/EM&gt; key as a way to label your content and provider directories.&amp;nbsp; This requires creating a 1024x96 pixel PNG or JPEG, copying it to the content or provider directory, and setting the [language]-icon key to the location of the image.&amp;nbsp; However, it should be noted that the player may only use the [language]-explanation key and not the [language]-icon key, so if you should chose to use &lt;EM&gt;[language]-icon&lt;/EM&gt;, be sure to set &lt;EM&gt;[language]-explanation&lt;/EM&gt; as a backup.&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=4405064" width="1" height="1"&gt;</description><enclosure url="http://blogs.msdn.com/amyd/attachment/4405064.ashx" length="20268" type="application/x-zip-compressed" /><category domain="http://blogs.msdn.com/amyd/archive/tags/HD+DVD/default.aspx">HD DVD</category><category domain="http://blogs.msdn.com/amyd/archive/tags/HDi/default.aspx">HDi</category><category domain="http://blogs.msdn.com/amyd/archive/tags/script/default.aspx">script</category><category domain="http://blogs.msdn.com/amyd/archive/tags/sample+code/default.aspx">sample code</category></item></channel></rss>