Beispiel #1
0
        /// <summary>
        /// 转换为DataTable(内存流+表名)
        /// </summary>
        public static DataTable TranslateToTable(System.IO.Stream stream, string sheetName)
        {
            ExcelUtils utils = new ExcelUtils(stream);

            return(utils.ToDataTable(sheetName));
        }
Beispiel #2
0
        /// <summary>
        /// 转换为DataTable(内存流)
        /// </summary>
        public static DataTable TranslateToTable(System.IO.Stream stream)
        {
            ExcelUtils utils = new ExcelUtils(stream);

            return(utils.ToDataTable(0));
        }
Beispiel #3
0
        /// <summary>
        /// 转换为DataTable(文件路径+表索引)
        /// </summary>
        public static DataTable TranslateToTable(string path, int sheetIndex)
        {
            ExcelUtils utils = new ExcelUtils(path);

            return(utils.ToDataTable(sheetIndex));
        }
Beispiel #4
0
        /// <summary>
        /// 转换为DataTable(文件路径)
        /// </summary>
        public static DataTable TranslateToTable(string path)
        {
            ExcelUtils utils = new ExcelUtils(path);

            return(utils.ToDataTable(0));
        }
Beispiel #5
0
 /// <summary>
 /// ת��ΪDataTable(�ļ�·��+������)
 /// </summary>
 public static DataTable TranslateToTable(string path, int sheetIndex)
 {
     ExcelUtils utils = new ExcelUtils(path);
     return utils.ToDataTable(sheetIndex);
 }
Beispiel #6
0
 /// <summary>
 /// ת��ΪDataTable(�ļ�·��+����)
 /// </summary>
 public static DataTable TranslateToTable(string path, string sheetName)
 {
     ExcelUtils utils = new ExcelUtils(path);
     return utils.ToDataTable(sheetName);
 }
Beispiel #7
0
 /// <summary>
 /// ת��ΪDataTable(�ڴ���)
 /// </summary>
 public static DataTable TranslateToTable(System.IO.Stream stream)
 {
     ExcelUtils utils = new ExcelUtils(stream);
     return utils.ToDataTable(0);
 }
Beispiel #8
0
 /// <summary>
 /// ת��ΪDataTable(�ڴ���+������)
 /// </summary>
 public static DataTable TranslateToTable(System.IO.Stream stream, int sheetIndex)
 {
     ExcelUtils utils = new ExcelUtils(stream);
     return utils.ToDataTable(sheetIndex);
 }
Beispiel #9
0
 /// <summary>
 /// ת��ΪDataTable(�ڴ���+����)
 /// </summary>
 public static DataTable TranslateToTable(System.IO.Stream stream, string sheetName)
 {
     ExcelUtils utils = new ExcelUtils(stream);
     return utils.ToDataTable(sheetName);
 }