コード例 #1
0
        /// <summary>
        /// Covert Object to Date Time
        /// </summary>
        /// <param name="value"></param>
        /// <returns></returns>
        public static DateTime?ToDateTime(object value)
        {
            DateTime iDate;

            if (DateTime.TryParse(Utility.ToString(value), out iDate))
            {
                return(iDate);
            }
            else
            {
                return(null);
            }
        }
コード例 #2
0
 public string DateTimeValue(string colName, string format)
 {
     return(Utility.ToString(DateTimeValue(colName), format));
 }