阴山脚下菜鸟求高手帮忙解决下小小问题?
string myStrFileName1 = DateTime.Now.AddDays(0).ToString("MM");
int sheet;
sheet = Convert.ToInt32(myStrFileName1);
Microsoft.Office.Interop.Excel.Application excel2 = new Microsoft.Office.Interop.Excel.Application();
Excel.Workbook workbook1 = excel2.Workbooks._Open(@"D:\预警、重要报告、通报\副本巴市回归.xls", Missing.Value, Missing.Value, Missing.Value, Missing.Value, Missing.Value, Missing.Value, Missing.Value, Missing.Value
, Missing.Value, Missing.Value, Missing.Value, Missing.Value);
Excel.Sheets objSheets;
Excel._Worksheet objSheet;
Excel._Worksheet objSheet1;
Excel.Range range;//=new Range[100];
Excel.Range range1;//=new Range[100];
string[,] tdyb = new string[100, 100];
int[,] tgyb=new int [100,100];
int[,] tyb = new int[100, 100];
string[,] tgdyb = new string[100, 100];
objSheets = excel2.Worksheets;
objSheet = (Excel._Worksheet)objSheets.get_Item(sheet);
range = objSheet.get_Range("A1", "IT34");
// range1 = objSheet1.get_Range("A1", "GN32");