バージョン

GetAppointmentsInRange メソッド (Owner)

指定した日付範囲内に一部でも含まれている Appointment オブジェクトのコレクションを返します。
シンタックス
'宣言
 
Public Function GetAppointmentsInRange( _
   ByVal startDateTime As Date, _
   ByVal endDateTime As Date _
) As AppointmentsSubsetCollection
public AppointmentsSubsetCollection GetAppointmentsInRange( 
   DateTime startDateTime,
   DateTime endDateTime
)

パラメータ

startDateTime
予定の最も早い開始日時。
endDateTime
予定の最も遅い終了日時。

戻り値の型

startDateTime および endDateTime と重なる Appointment オブジェクトをすべて含む AppointmentsSubsetCollection
使用例
Imports Infragistics.Win
Imports Infragistics.Win.UltraWinSchedule

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
        If Not Me.UltraDayView1.ActiveOwner Is Nothing Then
            Dim activities As ArrayList = Me.GetOwnerActivity(Me.UltraDayView1.ActiveOwner, DateTime.Today, DateTime.Today.AddDays(1))
        End If
    End Sub

    Private Function GetOwnerActivity(ByVal theOwner As Infragistics.Win.UltraWinSchedule.Owner, ByVal startDate As DateTime, ByVal endDate As DateTime) As ArrayList

        If (Not theOwner Is Nothing) Then

            Dim activities As ArrayList = New ArrayList(100)

            activities.AddRange(theOwner.GetAppointmentsInRange(startDate, endDate))
            activities.AddRange(theOwner.GetNotesInRange(startDate, endDate))

            Return activities

        Else
            Return Nothing
        End If

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

		private void button1_Click(object sender, System.EventArgs e)
		{
			if ( this.ultraDayView1.ActiveOwner != null )
			{
				ArrayList activities = this.GetOwnerActivity( this.ultraDayView1.ActiveOwner, DateTime.Today, DateTime.Today.AddDays(1.0) );
			}

		}

		private ArrayList GetOwnerActivity( Infragistics.Win.UltraWinSchedule.Owner theOwner, DateTime startDate, DateTime endDate )
		{
			if ( theOwner != null )
			{
				ArrayList activities = new ArrayList( 100 );

				activities.AddRange( theOwner.GetAppointmentsInRange(startDate, endDate) );
				activities.AddRange( theOwner.GetNotesInRange(startDate, endDate) );

				return activities;
			}
			else
				return null;
		}
参照