08-09-2020 07:48 PM
Just a guess, but I noticed coercion dots on your CreateNewNode and AddChild VIs doc and parent node inputs. Have you made sure that the data-types for those VIs terminals and CLFN parameters have been updated to 64bit? If they are still 32 bit then the references will be invalid.
08-10-2020 06:34 AM
Hi TroyK,
many thanks for your tip. I fixed all the datatypes and now it´s working properly in LV x64!
12-03-2021 07:26 AM
Hi all,
I'm trying to select the "log" node inside an XML file.
Any idea why it doesn't work?
Below there's an extract of the file.
I've already validated the XML and there's no error in it.
<?xml version="1.0" encoding="utf-8"?>
<logs xmlns="http://www.witsml.org/schemas/1series" version="1.4.1.1" xsi:schemaLocation="http://www.witsml.org/schemas/1series ../xsd_schemas/obj_log.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<log uid="measurement">
<data>
1999.509,-0.438772,-0.92,513.655
</data>
</log>
</logs>
Thanks in advance for any help.
12-05-2021 08:15 PM - edited 12-05-2021 08:20 PM
I believe this has to do with the root element default namespace declaration in your XML: xmlns="http://www.witsml.org/schemas/1series"
See here: https://stackoverflow.com/questions/3135175/libxml2-error-with-namespaces-and-xpath
Child elements aren't required to be qualified (with a namespace prefix) in the XML doc, but technically they are required to be qualified with a namespace in XPATH queries.
libxml2 does have the function xmlXPathRegisterNs to register a namespace so it can be used in XPATH quesries but that function doesn't seem to be implemented in the IXMLwrap.dll for us to use in this LabVIEW wrapper version of libxml2.
So I think you have 3 options.
12-09-2021 08:11 AM
Thanks TroyK, that's exactly what I need. Unfortunately, I don't have control over the XML format but using the second option does the trick.