G
Guest
Hello,
How can I disable that message/question that appears when my program edits
an Excel file?
Here's the code:
Excel.Application excelApp = new Excel.ApplicationClass();
Excel.Workbook excelWorkbook = excelApp.Workbooks.Open( fileName, 0, false,
5, "", "", false, Excel.XlPlatform.xlWindows, "", true, false, 0, true,
false, false);
Excel.Sheets excelSheets = excelWorkbook.Worksheets;
Excel.Worksheet excelWorksheet =
(Excel.Worksheet)excelSheets.get_Item("Sheet1");
excelWorksheet.get_Range("A1", "A1").Value2 = "'Testing";
excelWorksheet.get_Range("A2", "A2").Value2 = "'Example";
etc. etc.
excelApp.Workbooks.Close();
The question that appears (from Excel) is the following "Do you want to save
changes you made to <filename>?"
Any ideas?
Thanks,
David
How can I disable that message/question that appears when my program edits
an Excel file?
Here's the code:
Excel.Application excelApp = new Excel.ApplicationClass();
Excel.Workbook excelWorkbook = excelApp.Workbooks.Open( fileName, 0, false,
5, "", "", false, Excel.XlPlatform.xlWindows, "", true, false, 0, true,
false, false);
Excel.Sheets excelSheets = excelWorkbook.Worksheets;
Excel.Worksheet excelWorksheet =
(Excel.Worksheet)excelSheets.get_Item("Sheet1");
excelWorksheet.get_Range("A1", "A1").Value2 = "'Testing";
excelWorksheet.get_Range("A2", "A2").Value2 = "'Example";
etc. etc.
excelApp.Workbooks.Close();
The question that appears (from Excel) is the following "Do you want to save
changes you made to <filename>?"
Any ideas?
Thanks,
David