-
Jul 27th, 2012, 08:04 PM
#1
Thread Starter
Lively Member
Can't load xml from string (.loadXml)
Hi guy's, I am well and truly stuck as to why the following code will not load xml into my xmlDocument variable from a string.
Code:
var stringXML = request.responseText;
var xmlDocument = new Windows.Data.Xml.Dom.XmlDocument();
xmlDocument.loadXml(stringXML);
I have triple checked that stringXML has the value that I am expecting, which is a text string.
This is a javascript html css metro style application. I just don't see why the loadXml function is not populating my xmlDocumet varable with the contents of stringXML. Also I have check the contents of the xmlDocument variable after loadXml has run and it is empty, I also find it weird that I don't get any errors.
Best Regards, Antony.
Last edited by anton2k; Jul 27th, 2012 at 08:07 PM.
-
Aug 13th, 2012, 01:48 PM
#2
Re: Can't load xml from string (.loadXml)
You should try a simple xml string containing nearly nothing, it should work. I've even managed to get it working to load a XAML string (since you are posting in the "Metro" subforum,see my blog post.
Could you post the value of stringXML?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|