Altova Mailing List Archives>Archive Index >microsoft.public.xml Archive Home >Recent entries >Thread Prev - Parseing XML in ASP Page >Thread Next - Re: Parseing XML in ASP Page Re: Parseing XML in ASP PageTo: 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/
| ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
