Beispiel #1
0
 private ISqlValue ToDateTime(SqlDateTime date, SqlDateTimeType destType)
 {
     return(destType.NormalizeValue(date));
 }
Beispiel #2
0
 private SqlNumber ToNumber(SqlDateTime date)
 {
     return((SqlNumber)date.Ticks);
 }
        public static void InvalidConvertTo(Type type)
        {
            var date = new SqlDateTime(2001, 12, 01);

            Assert.Throws <InvalidCastException>(() => Convert.ChangeType(date, type));
        }