if(excel!=null)
{
excel.Workbooks.Close();
excel.Quit();
int generation=System.GC.GetGeneration(excel);
excel=null;
System.GC.Collect(generation);
}
我一直用,绝对没问题
if(excel!=null)
{
excel.Workbooks.Close();
excel.Quit();
int generation=System.GC.GetGeneration(excel);
excel=null;
System.GC.Collect(generation);
}
我一直用,绝对没问题
转载于:https://www.cnblogs.com/zfking/archive/2006/09/17/506759.html