'Declaration Public Class UltraCalendarInfo Inherits System.ComponentModel.Component Implements Infragistics.Shared.IUltraComponent
public class UltraCalendarInfo : System.ComponentModel.Component, Infragistics.Shared.IUltraComponent
The UltraCalendarInfo component centralizes all the date specific state information into a single component that can be referenced from all the UltraSchedule controls (UltraScheduleControlBase.CalendarInfo). This allows the controls to share the same information across all the controls without the need to maintain the same information on each control.
Use the MinDate and MaxDate properties to change the minimum and maximum dates that the controls can use.
The ActiveDay property maintains the active day and affects each control which is attached to the instance of the UltraCalendarInfo.
The WeekRule and FirstDayOfWeek properties are used to determine when a week begins and also how to calculate the week numbers for a particular year.
The component exposes collections for general date ranges (e.g. MonthsOfYear, DaysOfWeek, etc.). You can also modify the state information for a specific date.
For example, to disable all days in December of every year, you would use the following syntax:
[C#]
this.ultraCalendarInfo1.MonthsOfYear[12].Enabled = false;
[VB]
Me.UltraCalendarInfo1.MonthsOfYear(12).Enabled = False
The more specific object's settings takes precedence over the general setting so if you then wanted to enable all the days in December, 2001, you would use the following syntax:
[C#]
this.ultraCalendarInfo1.GetMonth(12, 2001).Enabled = true;
[VB]
Me.UltraCalendarInfo1.GetMonth(12, 2001).Enabled = True
The component also contains collections to maintain the group of selected objects (e.g. SelectedDateRanges, SelectedAppointments, etc.). To control the selection behavior, use the SelectTypeDay and SelectTypeActivity. To limit the number of Day objects that may be selected, use the MaxSelectedDays property.
If the UltraScheduleControlBase.CalendarInfo property of an UltraSchedule control is not explicitly set to an instance of an UltraCalendarInfo, one will be created at runtime. At that point, no other UltraSchedule control would be listening to that instance of the UltraCalendarInfo and therefore, changes made through the UltraScheduleControlBase.CalendarInfo property would affect only that control. To gain the benefit of sharing the state information (e.g. Appointment, Note, etc.) information amongst the controls, place an instance of the UltraCalendarInfo on your form and set the UltraScheduleControlBase.CalendarInfo property to that component.
Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Server 2012, Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2