Microsoft.Office.Core.dll 下载.
Microsoft.Office.Interop.Excel.Workbooks 可以用来导出文档相关的内容,
Microsoft.Office.Interop.Excel.Workbooks workbooks = xlApp.Workbooks;
Microsoft.Office.Interop.Excel.Workbook workbook = workbooks.Add(Microsoft.Office.Interop.Excel.XlWBATemplate.xlWBATWorksheet);
Microsoft.Office.Interop.Excel.Worksheet worksheet = (Microsoft.Office.Interop.Excel.Worksheet)workbook.Worksheets[1];//取得sheet1
worksheet.Cells[1, 1] = "商品条形码";
worksheet.Cells[2, 1] = "123456789";
1