Version

Enabled Property (MonthOfYear)

Determines the enabled state of this object.
Syntax
'Declaration
 
Public Property Enabled As Boolean
public bool Enabled {get; set;}
Remarks
You can use the Enabled property to selectively activate or deactivate an object. When an object is disabled, its appearance changes (based on the system disabled colors) and it becomes unavailable to the user. Certain properties or methods of the object may also be unavailable through code when it is disabled.
Example
This example displays information about each month of the year using the MonthOfYear object.

Imports Infragistics.Win
Imports Infragistics.Win.UltraWinSchedule

    Private Sub GetMonthOfYearInfo()

        Dim info As String = String.Empty

        '	Iterate the component's MonthsOfYear collection
        Dim monthOfYear As Infragistics.Win.UltraWinSchedule.MonthOfYear
        For Each monthOfYear In Me.ultraCalendarInfo1.MonthsOfYear

            '	Display the month number and its long name
            Dim monthNumber As Integer = monthOfYear.MonthOfTheYear
            info += "Month number " + monthNumber.ToString() + " is named " + monthOfYear.LongDescriptionResolved
            info += "Its abbreviated name is: " + monthOfYear.ShortDescriptionResolved

            If monthOfYear.LongDescription <> String.Empty Then
                info += "The name of the month has been changed to '" + monthOfYear.LongDescription + "'" + vbCrLf
            End If

            If monthOfYear.ShortDescription <> String.Empty Then
                info += "The abbreviated name of the month has been changed to '" + monthOfYear.ShortDescription + "'" + vbCrLf
            End If

            '	Display whether the month is enabled
            If (monthOfYear.Enabled) Then
                info += " (Enabled)" + vbCrLf
            Else
                info += " (Disabled)" + vbCrLf
            End If

        Next

        MessageBox.Show(info, "GetMonthOfYearInfo", MessageBoxButtons.OK)

    End Sub
using System.Diagnostics;
using Infragistics.Win;
using Infragistics.Win.UltraWinSchedule;

		private void GetMonthOfYearInfo()
		{

			string info = string.Empty;

			//	Iterate the component's MonthsOfYear collection
			foreach ( Infragistics.Win.UltraWinSchedule.MonthOfYear monthOfYear in this.ultraCalendarInfo1.MonthsOfYear )
			{
				//	Display the month number and its long name
				info += "Month number " + ((int)(monthOfYear.MonthOfTheYear)).ToString() + " is named " + monthOfYear.LongDescriptionResolved;
				
				info += "Its abbreviated name is: " + monthOfYear.ShortDescriptionResolved;

				if ( monthOfYear.LongDescription != string.Empty )
					info += "The name of the month has been changed to '" + monthOfYear.LongDescription + "'" + "\n";

				if ( monthOfYear.ShortDescription != string.Empty )
					info += "The abbreviated name of the month has been changed to '" + monthOfYear.ShortDescription + "'" + "\n";

				//	Display whether the month is enabled
				if ( monthOfYear.Enabled )
					info += " (Enabled)" + "\n";
				else
					info += " (Disabled)"+ "\n";
			}

			MessageBox.Show( info, "GetMonthOfYearInfo", MessageBoxButtons.OK );

		}
Requirements

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

See Also