I use this code to convert an excel file to PDF. The problem is that the Excel process is not close. What am I missing?
        protected void Indexchanged_ConvertPDF(Object sender, EventArgs e)
    {
        Microsoft.Office.Interop.Excel.Application xlApp = new Microsoft.Office.Interop.Excel.Application();
        xlApp.DisplayAlerts = false;
        xlApp.Visible = false;
        xlApp.ScreenUpdating = false;
        string path = CertificadosPresion.SelectedRow.Cells[0].Text;
        string CertName = CertificadosPresion.SelectedDataKey.Value.ToString();
        Workbook xlWorkbook = xlApp.Workbooks.Open(path);
        xlWorkbook.ExportAsFixedFormat(Microsoft.Office.Interop.Excel.XlFixedFormatType.xlTypePDF, @"C:\pdf\" + SALESID.Text + "_CertPres.pdf", 0, false, true);
        xlWorkbook.Close();
        xlApp.Quit();
        xlApp = null;
        xlWorkbook = null;
        DisposeCOMObject(xlWorkbook);
        DisposeCOMObject(xlApp);
    }
 
     
    