Lists Home |
Date Index |
- From: Chris Lovett <email@example.com>
- To: "'firstname.lastname@example.org'" <email@example.com>,"Simon St.Laurent" <firstname.lastname@example.org>
- Date: Wed, 27 Sep 2000 23:43:36 -0700
You have to check the parseError object that hangs off the xml document
object to see if load failed or not (it is packaged this way because the
MSXML DOM also supports "async" loading.
loadXML() takes a BSTR which by definition is a UCS-2 (or UTF-16) format.
If you have a JScript string then you have a UTF-16 string and it should
work - so just chopping off the xml declaration is probably all that you
have to do in this case.
From: Francis Norton [mailto:email@example.com]
Sent: Wednesday, September 27, 2000 8:41 AM
To: Simon St.Laurent
Subject: Re: bug report: msxml3, loadXML()
"Simon St.Laurent" wrote:
> At 01:59 PM 9/27/00 +0100, Francis Norton wrote:
> >This caused me some grief. I think it's an absence-of-error-message bug
> It should be documented in the method documentation (and hopefully will
> be), but you might also want to take a look at "How to Encode XML Data", a
> piece Chris Lovett wrote for MSDN:
Thanks - useful article. I see I may have to find some way of accessing
SAFEARRAYs from server-side JScript - either that or establish that it
is in fact safe to simply knock out the xml declaration before the
On the absence-of-error-message point, the article above suggests (but,
I agree, does not *specify*) that this problem might generate a
Switch from current encoding to specified encoding not supported.
error message. In fact the attached query program generates no error
messages at all, as can be seen -
D:\xmlSchema>tableXpath table_0.xml "Francis Norton"
D:\xmlSchema>tableXpath table.xml "Francis Norton"