LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Unflate From XML Data Type

Hi there,
 
I'm trying to read an XML file using function Unflatten From XML.  Could not find an apropriate value for type input variable.  All values in xml file are strings, the output value obviously, should be string as well.
I'm using LabView 7.0.  Help file is hard to understand: see attached.  Is it a String, an Integer or some code expression?
 
Thanks,
Greg
0 Kudos
Message 1 of 4
(3,598 Views)
Greg:

The Unflatten from XML Vi takes as input an string created previously by the Flatten to XML VI. This VI "transforms" a LabVIEW datatype into a XML String, following the LabVIEW XML Schema. The datatype you see in the help file is a cluster compound of only numeric elements, but it may be any data type, such as as clusters, arrays, arrays of clusters, etc.

Check out the XML examples included in LabVIEW to see how this VIs work, in combination with the Write to XML/Read from XML VIs.

The XML VIs shipped with LabVIEW work with the LabVIEW XML Schema, so they don't read XML files that doesn't follow this schema. I tried but I couldn't Smiley Sad.

I don't know if somebody has already written some VIs for reading any type of XML file, but if so, surely somebody here in the forums will tell us.

Regards.

Robst.



Robst - CLD

Using LabVIEW since version 7.0


0 Kudos
Message 2 of 4
(3,588 Views)

Robst:

Thank you for the explanation.  One more limitation of LabView.

In my previous application written entirely in VB.NET 2005 I used System.XML namespace with full palette of XML read/write/parse tools. Can I implement some VB.NET classes or at least functions in LabView 7.0 application?

Thanks,

Greg

0 Kudos
Message 3 of 4
(3,579 Views)
Hello Greg:

LabVIEW can communicate with external code via ActiveX or DLLs. If you can export the functions you have in VB.NET 2005 to an ActiveX control or to a DLL you can easily use them in LabVIEW.

Here are three links that can help you in using ActiveX and DLLs in LabVIEW:

http://zone.ni.com/devzone/cda/tut/p/id/2983
http://zone.ni.com/devzone/cda/tut/p/id/4496
http://zone.ni.com/devzone/cda/tut/p/id/2719

Hope this helps.

Robst.




Robst - CLD

Using LabVIEW since version 7.0


0 Kudos
Message 4 of 4
(3,571 Views)