11-03-2015 09:40 AM
Hello Everyone,
I need my application to be able to write to an already existing XML file.
The XML file is of this type:
<XML>
<Parameter x="1" y="2"/>
</XML>
The user should be able to add tags so that the resulting XML looks like this:
<XML>
<Parameter x="1" y="2"/>
<Parameter x="3" y="4"/>
</XML>
So basically I need to add tags programmatically.
Suggestions?
Thanks
11-03-2015 10:53 AM
Which version of LabVIEW are you using? In older versions of LabVIEW the built-in VIs for unflatten/flatten to XML only work with the NI XML Schema. In 2013 (?) onwards, there are additional functions for parsing/modifying XML files using property/method nodes:
I think there are also other toolkits available on the tools network (look in package manager), you can also use .NET - it has a library for dealing with XML.
11-03-2015 04:38 PM - edited 11-03-2015 04:43 PM
Maybe something like this:
You could also do some traditional string manipulation: