I have a program that uses a dynamically created reports in excel, and prints them out to a pdf. I am having a problem with some of the reports that run for 4-5 hrs. Excel memory usage starts to exceed the system limits, and I can not determine a way of clearing some of the memory with开发者_Python百科out killing the application process. Does anyone have any incite? I can't kill and restart Excel process because my objects, in the Excel Object in C#, need to persist some information. THanks.
First of all, I suggest that you can prepare your data in database first, because the dynamically invoking is really slow.
Just let your excel api application to do the works about display and convert.
Did you try using excel.Visible = true
to show the excel UI?
精彩评论