![]() |
Excel runs much slower in console app
Hi,
I've got an app that can either run with a GUI or in a console. The app retrieves a report from Reporting Services and then merges it with a Excel template. The code that processes the reports it's exactly the same, whether you run with GUI or without. The problem is the Excel automation code runs about 10 times slower in console mode. For instance, the Workbook.SaveAs() method takes about a minute in console mode and a few seconds in GUI mode. Again, the only difference between the two modes is one shows a form the other displays a console. Any ideas would be much appreciated. Thanks |
Excel runs much slower in console app
Ok, just after I made the original post, I figured the problem out. I
needed to add Application.Run() (with no parameters), and then call Application.Exit() when the reports finished processing. Must have something to do with starting a message pump for the process. Thanks |
All times are GMT +1. The time now is 10:31 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com