kobus_2000

kobus_2000

  • NA
  • 14
  • 0

Stopping Excel process inside C#?

Jul 18 2005 5:08 AM
Hi

I am connecting to an Excel workbook using the Microsoft.Jet.OLEDB in a C# windows application.

I create a connection string (OleDbConnection conn = new OleDbConnection(connString);) and manages to open the connection and retrieve data from the workbook into a OleDbDataReader.
At the end of the method I close the connection (using conn.Close()).

In the task manage however I see that EXCEL is stil an active process and I cannot open any of my Excel workbooks until I stop the EXCEL process in the Task Manager.

How will I stop the excel process insede my C# code?

Thanks

Kobus

Answers (2)