Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7418589
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T07:54:51+00:00 2026-05-29T07:54:51+00:00

I have a ASP.net application on IIS. In this app I created a Excel

  • 0

I have a ASP.net application on IIS.
In this app I created a Excel application:

using Excel = Microsoft.Office.Interop.Excel;
public Excel.Application ExlApp;
//
public Excel.Workbook ExlWb;
//
public Excel.Worksheet ExlWs;

During the application work, I created a new workbooks and in finally, I destroy my objects:

        GC.Collect();
        GC.WaitForPendingFinalizers();

        Marshal.ReleaseComObject(ExlWs);        

        ExlWb.Close(Type.Missing, Type.Missing, Type.Missing);
        Marshal.ReleaseComObject(ExlWb);

The problem: during the work, the EXCEL proces is growing up in memory, how can I close the workbooks correct?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-29T07:54:52+00:00Added an answer on May 29, 2026 at 7:54 am

    Maybe you should look at replacing the Excel automation with OpenXML processing. Automating office applications server side is an unsupported scenario:

    http://support.microsoft.com/kb/257757

    “Microsoft does not currently recommend, and does not support, Automation of Microsoft Office applications from any unattended, non-interactive client application or component (including ASP, ASP.NET, DCOM, and NT Services), because Office may exhibit unstable behavior and/or deadlock when Office is run in this environment.”

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have created an multi thread application on IIS (ASP.NET MVC), When the threading
I have an ASP.NET 2.0 application under IIS that has the functionnality of exporting
I run an ASP.NET application on IIS 6.0. Usually I have compression turned on
I have a asp.net 3.5 application hosted on IIS 7.0. I'm looking for a
I have a ASP.NET MVC application that runs in both IIS 6 and 7.
I have to deploy my ASP.NET application into two seperated IIS servers. My application
I have an ASP.NET 2.0 application that I am deploying to an IIS 6.0
I have a ASP.NET 1.1 application running on IIS 6 / Windows Server 2003.
I have an Asp.Net MVC 2 web application deployed on IIS 7.5 on .Net
We have an ASP.NET web application running in IIS that uses the SoapHttpClientProtocol class

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.