Reputation: 1454
I have seen programs exporting to Excel in two different ways.
Number 1 is terribly slow and to me it is just plain aweful.
Number 2 is what I need to do. I'm guessing I need some sort of SDK so that I can create Excel files in C++.
Upvotes: 10
Views: 28297
Reputation: 7725
I'm doing this via Wt library's WTemplate
In short, I created the excel document I wanted in open office, and save-as
excel 2003 (.xml)
format.
I then loaded that in google-chrome to make it look pretty and copied it to the clipboard.
Now I'm painstakingly breaking it out into templates so that Wt can render a new file each time.
Upvotes: 0
Reputation: 5823
You can also try working with XLS
/XLSX
files over ODBC
or ADO
drivers just like databases with a limited usage. You can use some templates if you need formatting or create the files from stratch. Of course you are limited by playing with the field values that way. For styling etc. you will need to use an Excel
API like Microsoft
's.
Upvotes: 0
Reputation: 12212
You can easily do that by means of the XML Excel format. Check the wikipedia about that:
http://en.wikipedia.org/wiki/Microsoft_Excel#XML_Spreadsheet
This format was introduced in Excel 2002, and it is an easy way to generate a XLS file.
Upvotes: 12