C# 클래스 Ywdsoft.Utility.Excel.ExcelImportHelper

Excel导入公共类
파일 보기 프로젝트 열기: CrazyJson/TaskManager 1 사용 예제들

공개 메소드들

메소드 설명
GetCellMsg ( object cellValue, string colName, int MaxLength, bool Required = false, bool isNChar = false ) : string

GetErrorExcel ( IWorkbook wb, string fileName ) : string

获取错误信息Excel

GetLength ( string str, int chinaLength = 2 ) : int

获取字符串长度。与string.Length不同的是,该方法将中文作 x 个字符计算。

ObjectIsNullOrEmpty ( object obj ) : bool

判断对象是否为空

메소드 상세

GetCellMsg() 공개 정적인 메소드

public static GetCellMsg ( object cellValue, string colName, int MaxLength, bool Required = false, bool isNChar = false ) : string
cellValue object
colName string
MaxLength int
Required bool
isNChar bool
리턴 string

GetErrorExcel() 공개 정적인 메소드

获取错误信息Excel
public static GetErrorExcel ( IWorkbook wb, string fileName ) : string
wb IWorkbook excel对象
fileName string 文件名称
리턴 string

GetLength() 공개 정적인 메소드

获取字符串长度。与string.Length不同的是,该方法将中文作 x 个字符计算。
public static GetLength ( string str, int chinaLength = 2 ) : int
str string 目标字符串
chinaLength int 中文作x个字符 默认为2个
리턴 int

ObjectIsNullOrEmpty() 공개 정적인 메소드

判断对象是否为空
public static ObjectIsNullOrEmpty ( object obj ) : bool
obj object 待判断对象
리턴 bool