C#Excel后期绑定设置数据库与单元格

我有一个interresting问题,由于重写我的出口我跑了一些麻烦。 随着下面的代码,我尝试在我的Excelworkbook中填充分割的范围。 结果是真的很奇怪,Range(tpl_p1)的第一部分填充正确,但是第二部分填充非常奇怪,请参阅截图。

openExcel(@"C:\bla\test.xlsx", "Tabelle1"); ArrayList posData = new ArrayList(); int lines = 30; string[,] fo = new string[lines, 7]; for (int a = 0; a < lines; a++) { fo[a, 0] = "1"; fo[a, 1] = "2"; fo[a, 2] = "3"; fo[a, 3] = "4"; fo[a, 4] = "5"; fo[a, 5] = "6"; fo[a, 6] = "7"; } int i = 0; object rng; object[] rgums = new Object[1]; // { "A1:C70","E1:H70" }; object[] argums = new Object[1]; rgums[0] = "tpl_p1;tpl_p2"; try { rng = Sheet.GetType().InvokeMember("Range", System.Reflection.BindingFlags.GetProperty, null, Sheet, rgums); argums[0] = 1; rng.GetType().InvokeMember("Select", System.Reflection.BindingFlags.InvokeMethod, null, rng, null); argums[0] = fo; rng.GetType().InvokeMember("Value", System.Reflection.BindingFlags.SetProperty, null, rng, argums); } catch (Exception ex) { createErrorReport(ex, "Com"); } 

在这里Excel中的结果: 结果

我不明白为什么Array在Range的第二部分被破坏。