Read Excel sheet using ADO on Visual C++ -


We have an old application using VC ++ which uses the ODBC driver to read Excel data.

There is a problem with the current code with the mixed data types and boundaries of the ODBC driver.

So I am planning to use the Jet Ole DB driver and the use of the ADO

I open the ADO connection and read the Excel sheet. No issue ..

The biggest problem is called every, open (), it brings excel sheet and shows the user (if it is not already open). I tried to check the parameters, but there was no suggestion to hide the main Excel window.

Any suggestions?

The connection string I am using

Provider = 'Microsoft.JET.OLEDB.4.0'; Data source = temp.xls; Expanded Properties = "Excel 8.0; IMX = 1; HDR = No"

Three options Spring:

  1. Use the automation to open the spreadsheet in the hidden window. To wit. You can make an example of Excel application, hide the main window, and open a spreadsheet in that window.
  2. Use the ISAM driver instead of the JAT driver. Although it can change behavior in an undesirable way.
  3. Live with it.

Comments

Popular posts from this blog

qt - switch/case statement in C++ with a QString type -

python - sqlite3.OperationalError: near "REFERENCES": syntax error - foreign key creating -

Python's equivalent for Ruby's define_method? -