Page 1 of 1

*BEGINNER* Need a simple example...

Posted: Mon Sep 03, 2012 12:57 am
by FALKOR
Hi;

i need to export a Query result (dataset) to an Excel file, does any one have a simple example (in Delphi 7) from where i can make y first step with XLSReadWriteII ?

TIA

Re: *BEGINNER* Need a simple example...

Posted: Tue Sep 04, 2012 8:38 am
by Joe Griffin
I have a routine I've used for several years It's got a couple of non-general bits in it ...

1) I use a Raize SaveDialog to get specify where the file will be saved. (This can easily be replaced with a standard SaveDialog.)

2) I use my own MessageDialog (based on something from Delphi Informant in the Delphi 1 days). This would need to be replaced with a standard call.

It's written in Delphi 7 (I've never moved on from that most stable version!) and is about 240 lines long, so too long to post here.

Please drop me an email to gerbilsoft <at> btinternet <dot> com , with a title of "SaveToSpreadsheet" and I'll send you a copy.

Best regards,