Gets/sets whether the end time of an
Appointment is displayed.
Demonstrates how to use the ActivityDisplayStyle property to display only appointments and notes; demonstrates how to make appointment times display as an analog clock, and to ensure the displaying of appointment end times
Imports Infragistics.Win
Imports Infragistics.Win.UltraWinSchedule
Imports Infragistics.Win.UltraWinSchedule.MonthViewSingle
Private Sub SetupActivityDisplay()
' Add an appointment, note and holiday for the current date
Dim startTime As DateTime = New DateTime(DateTime.Today.Year, DateTime.Today.Month, DateTime.Today.Day, 9, 0, 0)
Dim endTime As DateTime = New DateTime(DateTime.Today.Year, DateTime.Today.Month, DateTime.Today.Day, 17, 30, 0)
Me.UltraMonthViewSingle1.CalendarInfo.Appointments.Add(startTime, endTime, "Today's Appointment")
Me.UltraMonthViewSingle1.CalendarInfo.Notes.Add(DateTime.Today, "Today's Note")
' Set the ActivityDisplayStyle property to display Appointments and Notes, but not Holidays
Me.UltraMonthViewSingle1.ActivityDisplayStyle = ActivityDisplayStyleEnum.Appointments Or ActivityDisplayStyleEnum.Notes
' Set the TimeDisplayStyle property to display Appointment times as an analog clock
Me.UltraMonthViewSingle1.TimeDisplayStyle = TimeDisplayStyleEnum.Clock
' Set the AppointmentEndTimeVisible property to display the end time of Appointments
Me.UltraMonthViewSingle1.AppointmentEndTimeVisible = True
End Sub
'Declaration
Public Property AppointmentEndTimeVisible As Boolean
using Infragistics.Win;
using Infragistics.Win.UltraWinSchedule;
using Infragistics.Win.UltraWinSchedule.MonthViewSingle;
using System.Diagnostics;
private void SetupActivityDisplay()
{
// Add an appointment, note and holiday for the current date
DateTime startTime = new DateTime( DateTime.Today.Year, DateTime.Today.Month, DateTime.Today.Day, 9, 0, 0 );
DateTime endTime = new DateTime( DateTime.Today.Year, DateTime.Today.Month, DateTime.Today.Day, 17, 30, 0 );
this.ultraMonthViewSingle1.CalendarInfo.Appointments.Add( startTime, endTime, "Today's Appointment" );
this.ultraMonthViewSingle1.CalendarInfo.Notes.Add( DateTime.Today, "Today's Note" );
// Set the ActivityDisplayStyle property to display Appointments and Notes, but not Holidays
this.ultraMonthViewSingle1.ActivityDisplayStyle = ActivityDisplayStyleEnum.Appointments |
ActivityDisplayStyleEnum.Notes;
// Set the TimeDisplayStyle property to display Appointment times as an analog clock
this.ultraMonthViewSingle1.TimeDisplayStyle = TimeDisplayStyleEnum.Clock;
// Set the AppointmentEndTimeVisible property to display the end time of Appointments
this.ultraMonthViewSingle1.AppointmentEndTimeVisible = true;
}
'Declaration
Public Property AppointmentEndTimeVisible As Boolean
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