NetTypeConverter() 공개 정적인 메소드

public static NetTypeConverter ( Type netType ) : ColumnType
netType System.Type
리턴 ColumnType
예제 #1
0
        static public ColumnType DatabaseToNetTypeConverter(object dbValue)
        {
            ColumnType result = ColumnType.Text;

            try
            {
                OleDbType columnType = (OleDbType)dbValue;
                result = Helper.NetTypeConverter(Helper.OleDbToNetTypeConverter(columnType));
            }
            catch { }
            return(result);
        }
예제 #2
0
        static public ColumnType DatabaseToNetTypeConverter(object dbValue)
        {
            ColumnType result = ColumnType.Text;

            try
            {
                OleDbType columnType = (OleDbType)Convert.ToInt32(dbValue);
                result = Helper.NetTypeConverter(Helper.OleDbToNetTypeConverter(columnType));
                if (columnType == OleDbType.WChar || columnType == OleDbType.VarWChar || columnType == OleDbType.LongVarWChar)
                {
                    result = ColumnType.UnicodeText;
                }
            }
            catch { }
            return(result);
        }