LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 
Reply

Convert .txt file into .xml file

Hello,

 

How do i convert an .txt file into an .xml file using labVIEW function?.

Also i do i extract the header from the text file.

 

My file format is mentioned in attached .txt file.

 

Also I need to extract the header from the converted .xml file.

 

Anticipating reply

0 Kudos
Message 1 of 2
(1,243 Views)

There is no automatic mechanism for converting a .txt file to XML in any language. You have to define the XML schema and then write the code to generate the XML file. You could also read in your text file into some form of structure and then use the Flatten to XML functions to use the NI XML schema. If you need to use your own XML schema then you would need to use the XML Parser VIs to generate your XML file. Alternatively, you could use LabXML or JKI's EasyXML Toolkit.

0 Kudos
Message 2 of 2
(1,219 Views)