C#操作Excel方法有很多,以前用的需要电脑安装office才能用,但因为版权问题公司不允许安装office.所以改用NPOI进行Excel操作,基本上一些简单的Excel操作都没有问题,读写合并单元格等都能实现. NPOI 库下载地址 命名空间: using NPOI; using NPOI.XSSF.UserModel; using NPOI.SS.UserModel; using NPOI.HSSF.UserModel; using NPOI.HSSF.Util; 简单的保存数据: pu
using System; using System.Collections.Generic; using System.Text; using Microsoft.Office.Interop.Excel; using System.IO; using System.Reflection; using System.Runtime.InteropServices; using Microsoft.Office.Core; namespace HustCAD.IntePLM.Win.BatchE
NPOI.dll 用法.单元格,样式,字体,颜色,行高,宽度.读写excel 转载:http://yuncode.net/code/c_531e679b3896495 view source print? 1.25 NPOI.dll using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; u