I am having an issue with the EXCEL app staying open in the task manager, even after I clean up (or think I am cleaning up) via code. Can anyone point out what I am missing from the snippet of code below:
private void btnBrowseSquid_Click(object sender, EventArgs e)
//starting up and defining the Excel references
Excel.Workbook squidBook = null;
Excel.Application excelApp = null;
Excel.Worksheet squidSheet = null;
string squidFileName = txtSquid.Text;
//Reading the information from the "Filenames" tab of the SQUID file into the Windows Form
excelApp = new Excel.Application();
excelApp.Visible = true;
squidBook = excelApp.Workbooks.Open(squidFileName);
squidSheet = squidBook.Sheets["Filenames"];
//do stuff here with the excel file
//close the open Excel App
squidBook.Close();
excelApp.Quit();
Marshal.FinalReleaseComObject(squidSheet);
Marshal.FinalReleaseComObject(squidBook);
}