Hi, I am trying to run the below code. I have used similar and it has worked.
However, when I try to open this with excel it complains about the format or file type.
Hopefully something simple. But I cant see it at the moment.
Thanks,
However, when I try to open this with excel it complains about the format or file type.
Hopefully something simple. But I cant see it at the moment.
Thanks,
C#:
xlWorkBook.SaveAs("C:\\DM\\Batches\\Batch" + BN + "\\" + strSN + "\\Updated" + strSN + "PWNNs.xlsx", Microsoft.Office.Interop.Excel.XlFileFormat.xlCSVWindows, Type.Missing, Type.Missing, false, false, Microsoft.Office.Interop.Excel.XlSaveAsAccessMode.xlExclusive, Microsoft.Office.Interop.Excel.XlSaveConflictResolution.xlLocalSessionChanges, false, Type.Missing, Type.Missing, Type.Missing);