Hi Masters,
I am using saxon 9.
When I create an element in XSLT like this,
Code:
<xsl:template match="/">
<w:document mc:Ignorable="w14 wp14" xmlns:wpc="http://schemas.microsoft.com/office/word/2010/wordprocessingCanvas" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships" xmlns:m="http://schemas.openxmlformats.org/officeDocument/2006/math" xmlns:v="urn:schemas-microsoft-com:vml">
<some code...../>
</w:document>
When the input XML is transformed using this XSL, the output contains the required elements, but the order of the attributes (namespaces) is changed and order randomly.
Code:
<w:document xmlns:wpc="http://schemas.microsoft.com/office/word/2010/wordprocessingCanvas" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships" xmlns:m="http://schemas.openxmlformats.org/officeDocument/2006/math" xmlns:v="urn:schemas-microsoft-com:vml" mc:Ignorable="w14 wp14">
<some code...../>
</w:document>
Though this doesn't harm anything, I am not able to see the required output in Word.
Can someone help me on how to retain the order of the attributes as mentioned in the XSL?