Example Code

How Can I Read Excel Data Into LabVIEW?

Code and Documents

Attachment

This example demonstrates how to use LabVIEW and ActiveX to programmatically read in Excel data. The user can specify a workbook and a specific worksheet, and then specify a range of cells in that sheet to read the data from. The data can be interpreted as string or numeric data, or 2D arrays of those.

The example is built to be modular, meaning that specific subVI's open and close workbooks and worksheets. This allows the user to iterate tasks, such as reading multiple ranges from a spreadsheet before closing it, or reading various spreadsheets in a loop before closing a workbook.

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

Contributors