How Calendar only shows "One, Second, Third ... Day", does not show "Week"

xiaoxiao2021-03-06  117

Autumn water without hate ASP.NET Calendar Daynameformat Globalization DayNames

http://www.9cbs.net/develop/read_article.asp?id=15715

Calendar's DayNameFormat, such as Firstletter, Firstttwoldters, Full, Short but struggles to speak English, so I am like modifying DateTimeFormatinfo DAYNames to achieve, such as

System.globalization.datetimeformatinfo.currentinfo.daynames = new string [] {"1", "two", "three", "four", "five", "six", "seven"}

But to pay attention to two points. CurrentInfo must be instantiated, there can be two ways

Globalization settings in web.config, such as culture = "en-us" modifies the Culture of the current page, such as <% @ Page Culture = "EN-CN"%> 2. Calendar's DayNameFormat cannot be set to short, such as

DaynaMeformat = "full" daynaMeformat = "firstletter"

According to the above method, the prompt "instance is read-only when running to the following sentence."? ? Why is that? ? ? Please try! System.globalization.datetimeformatinfo.currentinfo.daynames = new string [] {"1", "two", "three", "four", "five", "six", "seven"}; // instance is read-only .

转载请注明原文地址:https://www.9cbs.com/read-101505.html

New Post(0)