DateTimeFormatInfo.CalendarWeekRule 属性

定义

获取或设置一个值,该值指定使用哪一规则确定该年的第一个日历周。Gets or sets a value that specifies which rule is used to determine the first calendar week of the year.

public:
 property System::Globalization::CalendarWeekRule CalendarWeekRule { System::Globalization::CalendarWeekRule get(); void set(System::Globalization::CalendarWeekRule value); };
public System.Globalization.CalendarWeekRule CalendarWeekRule { get; set; }
member this.CalendarWeekRule : System.Globalization.CalendarWeekRule with get, set
Public Property CalendarWeekRule As CalendarWeekRule

属性值

一个值,该值确定该年的第一个日历周。A value that determines the first calendar week of the year. InvariantInfo 的默认值是 FirstDayThe default for InvariantInfo is FirstDay.

异常

该属性正被设置的值不是有效的 CalendarWeekRule 值。The property is being set to a value that is not a valid CalendarWeekRule value.

在设置操作中,当前的 DateTimeFormatInfo 对象是只读的。In a set operation, the current DateTimeFormatInfo object is read-only.

注解

如果Calendar属性的值发生更改,则此属性将受到影响。This property is affected if the value of the Calendar property changes.

适用于

另请参阅