[Urgent] C++ ODBC/ADO -> Excel 2007 file

Questions about programming languages and debugging
Post Reply
User avatar
ayu
Staff
Staff
Posts: 8109
Joined: 27 Aug 2005, 16:00
18
Contact:

[Urgent] C++ ODBC/ADO -> Excel 2007 file

Post by ayu »

I need to find how to connect to a Excel 2007 file using C++ and extract data. I have found several forums where they TALK about it, but never any information about what libraries to use, where to find them, or how to use them with the Excel drivers (in case of ODBC).

Any help in finding this information will be very much appreciated (I'm on a deadline and the information I had before about this turned out to be wrong, so I need to search for a new method).

PS: If anyone decides to help, then please don't just google it and post the first link you see. If you don't know what your are looking at/for then don't bother, because I don't have much time on my hands.

Thanks in advance!
"The best place to hide a tree, is in a forest"

User avatar
Gogeta70
^_^
^_^
Posts: 3275
Joined: 25 Jun 2005, 16:00
18

Post by Gogeta70 »

I don't know if this will help, but maybe it will ^_^

http://www.libxl.com/

I haven't coded in C++ in a looong time XD
¯\_(ツ)_/¯ It works on my machine...

User avatar
ayu
Staff
Staff
Posts: 8109
Joined: 27 Aug 2005, 16:00
18
Contact:

Post by ayu »

gogeta70 wrote:I don't know if this will help, but maybe it will ^_^

http://www.libxl.com/

I haven't coded in C++ in a looong time XD
Yeah but it's really expensive, and the trial is useless :(
"The best place to hide a tree, is in a forest"

User avatar
Gogeta70
^_^
^_^
Posts: 3275
Joined: 25 Jun 2005, 16:00
18

Post by Gogeta70 »

I remember that in PHP, you can modify excel 2007 documents - here is how they did it:

http://openxmldeveloper.org/articles/De ... ntent.aspx

Maybe that will help ^_^
¯\_(ツ)_/¯ It works on my machine...

User avatar
ayu
Staff
Staff
Posts: 8109
Joined: 27 Aug 2005, 16:00
18
Contact:

Post by ayu »

Thanks for the suggestions Gog : - )

I found a professor at the uni who knew of a good solution.

First I make a function that uses Excels own functions to export it to a text file with tab separated data. Then I use SQL to import it to the database : )
"The best place to hide a tree, is in a forest"

User avatar
Gogeta70
^_^
^_^
Posts: 3275
Joined: 25 Jun 2005, 16:00
18

Post by Gogeta70 »

Lol, i tried ^_^

At least you got it all figured out.
¯\_(ツ)_/¯ It works on my machine...

Post Reply