using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Data; using System.Data.OleDb; using System.IO; namespace MyExcel { public class MyExcelReader { /// <summary> /// Access 数据库连接字符串 /// </summary> private string strConnectionn; /// <summary> /// 要操作的Excel文件路径 /// </summary> private string filePath; /// <summary> /// Excel文件表名 /// </summary> private string tableName; /// <summary> /// 文件行数 /// </summary> private int rowCount; /// <summary> /// 列数 /// </summary> private int columnCount; /// <summary> /// 读取Excel文件到DataSet /// </summary> private DataSet data; #region 属性 public DataSet DataSet { get { return this.data; } set { this.data = value; } } public string FilePath { get { return this.filePath; } set { this.filePath = value; } } public string TableName { get { return this.tableName; } set { this.tableName = value; } } public string StrConnection {