[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

multiple xml files

Subject: multiple xml files
From: "katharine wykes" <katharinewykes@xxxxxxxxxxx>
Date: Tue, 08 Oct 2002 16:13:59 +0000
msxml2.xsltemplate40


I am using asp to load in xml and xsl files to create an output. I am using the msxml parser, and for single xml files I am using the following asp code:
set objXml = Server.CreateObject("MSXML2.FreeThreadedDOMDocument")
objXml.async = false
objXml.load(Server.MapPath(srcXml))


	set objXsl = Server.CreateObject("MSXML2.FreeThreadedDOMDocument")
	objXsl.async = false
	objXsl.load(Server.MapPath(srcXsl))

	'add parameters to the xsl
	Set objXSLTemplate = Server.CreateObject("MSXML2.XSLTemplate")
	Set objXSLTemplate.stylesheet = objXsl
	Set prXSLT = objXSLTemplate.createProcessor

I need to use something similar to this but with multiple xml files, I don't want to use the document() functionality, as I need to dynamically set the xml files to load through the asp code. I've found the following code that will load in an xml file through the asp (well VB):
Dim xmlXSLT as New MSXML2.FreeThreadedDOMDocument40
Dim xslTemplate as New MSXML2.XSLTemplate40
Dim xprProcessor as IXSLProcessor


   xmlXSLT.load("c:\temp\MyTransform.xsl")
   ' don't forget to check for parseError!
   Set xslTemplate.stylesheet = xmlXSLT.documentElement
   Set xprProcessor = xslTemplate.createProcessor

   With xslTemplate
       .input = xmlSource
       .output = xmlResult
       .addParameter "DocPath", "c:\temp\MyDoc.xml"
       .transform
   End With

Is this the best way to load in multiple xml files?
Does anyone have an example of vb script code that loads an array of multiple/dynamic xml files and transforms them using 1 xsl file?


Any help would be appreciated. The end result will be a press release style list that gets summary information from different xml files, based on their dates.

Cheers,
Kate




_________________________________________________________________ Send and receive Hotmail on your mobile device: http://mobile.msn.com


XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list



Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.