Monday, 2 December 2013

Accessing network drives in XSLT


I have an xml document that lists several folders:


and these need to be used to create three result documents on a shared folder on the network using Saxon 9 as the transformation engine.


Using the simple template:

<xsl:template match="folder">
  <xsl:result-document href="{.}/new.xml" method="xml">

we can specify the absolute path in the href attribute.


Map the shared folder on the network drive to a local drive letter and use the following:


Write directly to the shared folder on the drive (note the four forward slashes)


No comments:

Post a Comment