XLS file-format
Ej,
Not really programming in Excel, so a little OT.... I'd like to create an Excel-file from within a little program I'm writing. It has to export query-results to a file, readable for Excel. Creating tsv or csv is not really an option, since I don't want to be bothered with the import options when opening such files. So now I need to know how xls-files are built, what info they contain etc. Anyone got a hint where to find this info, if it is available at all? Other suggestions are welcome too, workarounds are programmable too :-) TIA! -- CloudsŪ |
XLS file-format
saving as a CSV would not involve formats
However, you havent' said what language you are programming in. In VB6, VB.Net set a reference to the MS Excel Objects Library. Having done so yuo can instantaite the application, ad a workbook, popu;ate teh sheets etc and save the workbook. Without knowing what you're intending, its a tough question. However, you can examine the object model in the object browser. Patrick Molloy Microsoft Excel MVP -----Original Message----- Ej, Not really programming in Excel, so a little OT.... I'd like to create an Excel-file from within a little program I'm writing. It has to export query-results to a file, readable for Excel. Creating tsv or csv is not really an option, since I don't want to be bothered with the import options when opening such files. So now I need to know how xls-files are built, what info they contain etc. Anyone got a hint where to find this info, if it is available at all? Other suggestions are welcome too, workarounds are programmable too :-) TIA! -- CloudsŪ . |
XLS file-format
"Patrick Molloy" schreef in bericht ... However, you havent' said what language you are programming in. Using Delphi 5...but the program is a plugin for a third-party app, and hence subject to limitations... Without knowing what you're intending, its a tough question. However, you can examine the object model in the object browser. The third-party app queries a database and returns an array with the results. This array should be saved in xls-format. I can have my plugin iterate through all records and rows, and doing that should result in the code to write the xls-file. Already found some information on the format, http://sc.openoffice.org/excelfileformat.pdf Now looking in Delphi for built-in Excel-functions....I'm not a very experienced programmer :-) -- CloudsŪ |
XLS file-format
You could try writing out the data as an HTML table in plain text and saving
the file with an xls extension. Should be OK with xl97+. You can use css formatting to tart it up. Tim "CloudsŪ" wrote in message .nl... "Patrick Molloy" schreef in bericht ... However, you havent' said what language you are programming in. Using Delphi 5...but the program is a plugin for a third-party app, and hence subject to limitations... Without knowing what you're intending, its a tough question. However, you can examine the object model in the object browser. The third-party app queries a database and returns an array with the results. This array should be saved in xls-format. I can have my plugin iterate through all records and rows, and doing that should result in the code to write the xls-file. Already found some information on the format, http://sc.openoffice.org/excelfileformat.pdf Now looking in Delphi for built-in Excel-functions....I'm not a very experienced programmer :-) -- CloudsŪ |
All times are GMT +1. The time now is 01:57 PM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com