Example Code

Query XML Document for Different Expressions Using LabVIEW

Products and Environment

This section reflects the products and operating system used to create the example.

To download NI software, including the products shown below, visit ni.com/downloads.

    Software

  • LabVIEW

Code and Documents

Attachment

Overview

This VI will query an XML document for three different expressions and return the output of those expressions.


Description
This VI is used to read the "/method/lowleveldata/transitiontable/transitions/string"  node from an XML file as generated by the method editor. This VI will display only the first result of each expression.

 

Requirements

  • LabVIEW 2012 (or compatible)


Steps to Implement or Execute Code

  • Specify path of XML Document (Sample XML Document is attached)
  • Specify XPath Expression
  • Specify XPath Expression 2
  • Specify XPath Expression 3
  • Run the program

 

Additional Information or References
VI Snippet

3-382.png

**This document has been updated to meet the current required format for the NI Code Exchange.**

National Instruments
Applications Engineer

Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.