显示年月日星期

几一下以备以后使用

public string CurrentDate
    {

        get
        {
            System.Globalization.CultureInfo cultureInfo = new System.Globalization.CultureInfo("zh-CN");
            string buffer = cultureInfo.DateTimeFormat.GetAbbreviatedDayName(System.DateTime.Now.DayOfWeek);
            string res1 = System.DateTime.Now.ToString("yyyy年MM月dd日 星期");

            res1 += buffer;
            return res1;

        }
    }

你可能感兴趣的:(String,buffer)