TimeZoneInfo::TransitionTime::CreateFixedDateRule Method (DateTime, Int32, Int32)
Defines a time change that uses a fixed-date rule (that is, a time change that occurs on a specific day of a specific month).
Assembly: mscorlib (in mscorlib.dll)
public: static TimeZoneInfo::TransitionTime CreateFixedDateRule( DateTime timeOfDay, int month, int day )
The time at which the time change occurs. This parameter corresponds to the TimeOfDay property. For details, see Remarks.
The month in which the time change occurs. This parameter corresponds to the Month property.
Return ValueType: System::TimeZoneInfo::TransitionTime
Data about the time change.
The month parameter is less than 1 or greater than 12.
The day parameter is less than 1 or greater than 31.
This method creates a fixed-date rule (that is, a time change that occurs on a specific day of a specific month). For example, a time change that always occurs on October 28 follows a fixed-date rule.
For transitions from standard time to daylight saving time, the timeOfDay argument represents the time of the transition in the time zone's standard time. For transitions from daylight saving time to standard time, it represents the time of the transition in the time zone's daylight saving time. Note that this is a DateTime value whose year, month, and date values must all equal 1.
The following example creates time zone transitions for an imaginary time zone by using both a fixed-date rule and a floating-date rule. The fixed-date rule defines a time zone adjustment that starts at 2:00 A.M. on March 15 and ends at 3:00 A.M. on November 15 for the years 1900 to 1955.
Available since 3.5