David91
6 years agoFrequent Contributor
XML Parse - document load and parse from local disk
Hi, i need parse easy xml doc. if I upload a file as a string it's all right. But how do I load a file?
<root> <name> Giada De Laurentiis </name> <price> 30.00 </price> </root>
My parse code:
// to - do - this i need load and parse data from file
var xmlString = "<root><name>Giada De Laurentiis</name><price>30.00</price></root>";
var xmlDataObj = ParseXML(xmlString);
Log.Message(xmlDataObj.getElementsByTagName('price')[0].childNodes[0].nodeValue);
I try code from https://support.smartbear.com/testcomplete/docs/testing-with/advanced/working-with-external-data-sources/files/xml.html but it does not work for me..
Please help me :(... Thx