Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Populating a spreadsheet via a com object

Status
Not open for further replies.

TTPicasso

Programmer
Oct 3, 2001
6
GB
Hi chaps,

This is probably more of an excel / windows problem but somebody might have a suggestion.

We have a particular report which has to be formatted to look pretty fancy. To do this we populate a ready built excel spreadsheet via a com Object and using excel's API functions.

Ie. We will say in cell "A1" put "Title", in "A2" put "Main Report" etc till will populate every cell required.

Now this is all very fine until we come to the speed issue. When we put the program live it took twice as long as during testing. After extensive benchmarking it appears the speed for "POPULATING" the spreadsheet is linked to the printer you have set up as a default. It has nothing to do with spooling etc it's just the population of the spreadsheet. If I delete all printers from my PC the report is populated very quickly, the more "complex" a printer I add as a default the longer population takes.

I can only imagine that as I populate each cell excel is communicating with the default print driver to see how it is to be formatted or something like that.

Has anybody any idea how I can stop excel from interrogating the printer driver during population or indeed any idea as to exactly why the printer selection (even on a view only) directly affects the population speed?

We use progress 9.1d (A Gui 4GL SQL Language) on a mixture "NT" and "2000" platforms and use excel 2000.

Any suggestion will be much appreciated as I've hit a blank.

Thanks and Merry Xmas
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top