Transforming an XML STREAM coming from a dll

admin

Administrator
Staff member
I have an ASP page which calls a dll. The dll returns a STREAM which containsthe XML. How do I Transform the STREAM and the xslt file? I have no interestin saving the STREAM to a file.I'm using: IIS4.0, IE5, ADO2.5I have something like the following:<%Dim xml, xsl, stmDim myProcessorDim myTemplateDim XMLDLLSet xsl = Server.CreateObject("MSXML2.FreeThreadedDOMDocument")xsl.async = falsexsl.load Server.MapPath("XSLSource.xsl")Set myTemplate = Server.CreateObject("MSXML2.XSLTemplate")myTemplate.stylesheet = xslSet XMLDLL = Server.CreateObject("dll.class")'dll returns a STREAMSet stm = XMLDLL.GenerateXML("Cookie String")Set xml = Server.CreateObject("MSXML2.FreeThreadedDOMDocument")xml.async = false'We found that setting the position is important for some reasonstm.position = 0xml.loadXML (stm.ReadText(adReadAll))Set myProcessor = myTemplate.createProcessormyProcessor.input = xmlmyProcessor.transformResponse.Write(myProcessor.output)' stm.position = stm.size%>I appreciate any insight re: this problem.Holly
 
Back
Top