Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


Re: Parseing XML in ASP Page

From: Martin Honnen <mahotrash@-----.-->
To: NULL
Date: 11/1/2005 3:46:00 PM

John Beschler wrote:


> How do I parse an XML file within an ASP page?

Well with MSXML.

> We just purchased a google mini and it returns its results in XML. I need to 
> capture those results and parse them so that I can strip out pages that the 
> user does not have security access to.

What is a "google mini"?


>    Dim xmlDoc
>    Set xmlDoc = Server.CreateObject("Msxml2.DOMDocument.3.0")

>    xmlDoc.async = false
>    xmlDoc.load("C:\Temp\google.xml")
>    if xmlDoc.parseError.errorCode <> 0 Then
>       
>       Dim myErr 
>       Set myErr = xmlDoc.parseError
>       Response.Write "You have error " + myErr.reason

The code is fine to use MSXML 3 in classic ASP, if MSXML gives you a 
parsing error then the file you try to load there is probably not 
well-formed. Can you upload the file to a HTTP server and post the URL? 
Then we can check whether it is indeed not well-formed.


-- 

	Martin Honnen --- MVP XML
	http://JavaScript.FAQTs.com/


transparent
Print
Mail
Like It
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent