Exemple #1
0
        public static string GetDateStringddMMyyyyHHmmssWithLang(this DateTime?datetime)
        {
            if (!datetime.HasValue)
            {
                return(null);
            }

            var culture = AppConfigUtilities.CreateCulture("en");

            return(datetime.Value.ToString("ddMMyyyy HH:mm:ss", culture));
        }
Exemple #2
0
        public static string GetDateStrignDDMMMYY(this DateTime datetime, EnumLang lang)
        {
            var culture = AppConfigUtilities.CreateCulture(lang.ToString());

            return(datetime.ToString("d MMM yy", culture));
        }
Exemple #3
0
        public static string GetDateStringForSQLParam(this DateTime datetime)
        {
            var culture = AppConfigUtilities.CreateCulture("en");

            return(datetime.ToString("yyyy-MM-dd HH:mm:ss", culture));
        }