Microsoft.Office.Interop.Excel with "bad value" as default parameters

I am trying to use Microsoft.Office.Interop.Excel. It seems to load normally, but when I try to use it, all the default options do not work. Here is a screenshot that shows all those bad values

alt text

Whenever I try to omit them, the compiler tells me that a function requires more than one parameter.

This function is open as in:

   Microsoft.Office.Interop.Excel.Application excel = new Microsoft.Office.Interop.Excel.Application();
   Workbook wb = excel.Workbooks.Open("ss.xlsx");

How can I use the default value for these 14 parameters?

EDIT I ​​am using C # 3.5 (2008) with Office 2010

Decision:

. http://support.microsoft.com/default.aspx?scid=kb;en-us;320369 , - , , .

CultureInfo ci = new CultureInfo("en-US"); 
System.Threading.Thread.CurrentThread.CurrentCulture = ci;
+3
2

System.Type.Missing System.Reflection.Missing.Value , .

, ( ) Excel Interop "xlsx" ( 12 Office 2007).

+5

Source: https://habr.com/ru/post/1770791/


All Articles