private static string Culture_Get(enDayNameType DayNameType) { string strCulture = string.Empty; switch (DayNameType) { case enDayNameType.Eng: case enDayNameType.Eng_Long: strCulture = "en-US"; break; case enDayNameType.Han_Long: case enDayNameType.Han: strCulture = "ja-JP"; break; default: strCulture = "ko-KR"; break; } return(strCulture); }
/// <summary> /// 달명을 구한다. /// </summary> /// <param name="DayNameType"></param> /// <param name="dt"></param> /// <returns></returns> public static string MonthName_Get(enDayNameType DayNameType, DateTime dt) { string strFormat = string.Empty; string strCulture = Culture_Get(DayNameType); switch (DayNameType) { case enDayNameType.Eng_Long: case enDayNameType.Kor_Long: case enDayNameType.Han_Long: strFormat = "MMMMMM"; break; default: strFormat = "MMM"; break; } return(dt.ToString(strFormat, new System.Globalization.CultureInfo(strCulture))); }