Converting LabVIEW Data to XML

Converting LabVIEW data to XML formats the data so that when you save the data to a file, you easily can identify the value(s), name(s), and type of the data from the tags that describe the data.

Complete the following steps to convert LabVIEW data to the XML format.

  1. Select the Flatten to XML function on the Functions»Advanced»Data Manipulation»XML palette and place it on the block diagram.
  2. Wire the data you want to convert to the anything input of the Flatten to XML function.
  3. Right-click the xml string output of the function and select Create»Indicator from the shortcut menu. A string indicator terminal appears on the block diagram, and a string indicator appears on the front panel.
  4. Run the VI. LabVIEW converts the data type to the XML format according to the LabVIEW XML schema. The xml string indicator on the front panel displays the XML-formatted data.

Refer to the examples\file\XMLex.llb for examples of converting to the XML format.