Home » excel » excel – How to extract cell value of a spreadsheet in c++?

excel – How to extract cell value of a spreadsheet in c++?

Posted by: admin May 14, 2020 Leave a comment

Questions:

I would like to know how to extract the cell value (numbers) from a specified spreadsheet of Excel using c++.
What I am trying to achieve is iterate an entire column by using a “for” loop
Thanks
(i am using xcode)

How to&Answers:

There are pretty lots of libraries you can try out

Pick the one that suits your need.

QtXlsx

The QtXlsx library (https://github.com/dbzhang800/QtXlsxWriter) is the most feature complete. It is, however, based on the Qt framework. Not suitable for low footprint application.

XLNT

xlnt (https://github.com/tfussell/xlnt) is a modern C++ library for manipulating spreadsheets in memory and reading/writing them from/to XLSX files as described in ECMA 376 4th edition.

libxls

The libxls library (https://sourceforge.net/projects/libxls/) is a C library for reading files in the legacy Excel file format, .xls. It cannot be used for writing or modifying Excel files.

xlslib

The xlslib library (https://sourceforge.net/projects/xlslib/) is a C/C++ library for creating files in the legacy Excel file format, .xls. It cannot be used for reading or modifying Excel files.

libxlsxwriter

The libxlsxwriter library (https://libxlsxwriter.github.io) is a C library for creating .xlsx files. It cannot be used for reading or modifying Excel files.

LibXL (not free)

The LibXL library (http://www.libxl.com) can read, write, create and modify Excel files, in both the .xls and .xlsx formats. It is the most feature complete library available and has interfaces for C, C++, C# and Delphi.