So, in this entry, I wanted to explain the processing instruction that I included in my C# app that extracts my Outlook tasks to XML. I create an XML file on the fly (I use my own XSD to constrain it- more on that Monday), and I add this bit to the top of the XML. Here’s the basic structure of the XML.
<SummaryInfo>Status Report for: John R. Durant–2/25/2004</SummaryInfo>
<Task Subject=”Follow up on possible Content” Due=”2/9/2004″ PercentComplete=”0″>
<Notes>Check on the papers here: http://sdfasf/</Notes>
The mso-solutionextension processing instruction is key because it contains information that links the Word document to an XML Expansion Pack (XEP). Word will look for expansion packs with the same URI. The biggest key to success with expansion packs is this URI, because it ties everything together. In our case, the expansion pack is collection of XSL stylesheets. So, when Word opens the document, it loads the stylesheets listed for that URI in an expansion pack. That list is in a manifest file which is referenced in the attribue: manifestPath as shown above. Cool.
Then, the user can choose between between these stylesheets as you can see here:
This is what the user sees when opening the Word document (XML file). Each of the items in the list is a separte XSL.
Monday, I will describe the XSD, and then I will get into the manifest file itself. In my last entry of the series, I will walk through some of the XSL instructions as well.
Rock thought for the day: In the past 12 months, the best CD I purchased was by Zwan, title Mary Star of the Sea. The already disbanded group was headed by Billy Corgan. Their first and only CD is easily a must-have for those who love great guitar work. The other parts are equally amazing.