Company Events Academic Community Support Solutions Products & Services Contact NI MyNI

Read From XML File VI

LabVIEW 2013 Help

Edition Date: June 2013

Part Number: 371361K-01

»View Product Info

Owning Palette: LabVIEW Schema VIs and Functions

Requires: Base Development System

Reads and parses tags from a LabVIEW XML file. When you place this VI on the block diagram, the polymorphic VI selector is visible. Use this selector to choose which polymorphic instance to use. All XML data must follow the standard LabVIEW XML schema.

Example

Use the pull-down menu to select an instance of this VI.

Read From XML File(array)

XML File Path is the path and filename from which you want to read XML data. When you specify an empty path, a dialog box prompts the user to specify an XML file.
error in describes error conditions that occur before this node runs. This input provides standard error in functionality.
XML File Path(duplicate) is the path of the file from which the VI reads data. You can use this output to determine the file path that you selected through a dialog box. XML File Path(duplicate) has a value of <Not A Path> if you cancelled the dialog box.
XML Elements returns the top-level XML tags found between the end of the </Version> and </LVData> tags in an array of strings. You then can index the array and use the Unflatten From XML function.
error out contains error information. This output provides standard error out functionality.

Read From XML File(string)

XML File Path is the path and filename from which you want to read XML data. When you specify an empty path, a dialog box prompts the user to specify an XML file.
error in describes error conditions that occur before this node runs. This input provides standard error in functionality.
XML File Path(duplicate) is the path of the file from which the VI reads data. You can use this output to determine the file path that you selected through a dialog box. XML File Path(duplicate) has a value of <Not A Path> if you cancelled the dialog box.
XML Elements returns the top-level XML tags found between the end of the </Version> and </LVData> tags in a single string. You then can wire this output to the Unflatten From XML function.
error out contains error information. This output provides standard error out functionality.

Example

Refer to the Flatten and Unflatten XML.lvproj in the labview\examples\File IO\XML\Flatten and Unflatten XML directory for an example of using the Read From XML File VI.


 

Your Feedback! poor Poor  |  Excellent excellent   Yes No
 Document Quality? 
 Answered Your Question? 
Add Comments 1 2 3 4 5 submit