バージョン

MonthPadding プロパティ

Infragistics.Win.UltraWinSchedule.MonthViewMulti.VisibleMonth オブジェクトの周りの空白を設定します。
シンタックス
'宣言
 
Public Property MonthPadding As Size
public Size MonthPadding {get; set;}
解説

MonthPadding は、Infragistics.Win.UltraWinSchedule.MonthViewMulti.MonthUIElement で週の周りの余白サイズを決定します。これによって Infragistics.Win.UltraWinSchedule.MonthViewMulti.MonthUIElement のサイズを増やすことができ、したがって MonthDimensions によって決定されたようにすべての月を表示するために必要なサイズを増やすことができます。

MonthPadding の高さは週の最下部のみに適用され、幅は表示される週の左右両方に適用されます。

使用例
Imports Infragistics.Win
Imports Infragistics.Win.UltraWinSchedule
Imports Infragistics.Win.UltraWinSchedule.MonthViewMulti

    Private Sub SetupMonthOrientation()

        '	If there is only one month (or less) visible, the property
        '	setting is not applicable, so return
        If (Me.ultraMonthViewMulti1.VisibleMonths.Count <= 1) Then Return

        '	If there are 6 or more months being displayed, set the orientation
        '	to DownThenAcross, otherwise to AcrossThenDown
        If (Me.ultraMonthViewMulti1.VisibleMonths.Count >= 6) Then
            Me.ultraMonthViewMulti1.MonthOrientation = MonthOrientation.DownThenAcross
        Else
            Me.ultraMonthViewMulti1.MonthOrientation = MonthOrientation.AcrossThenDown
        End If

        '	Set the MonthPadding to be proportional to the number of
        '	months being displayed by the control
        Dim numberOfMonths As Integer = Me.ultraMonthViewMulti1.CalendarInfo.MonthsOfYear.Count
        If (Me.ultraMonthViewMulti1.VisibleMonths.Count <= numberOfMonths) Then
            Dim padSize As Integer = numberOfMonths - Me.ultraMonthViewMulti1.VisibleMonths.Count
            Dim padding As Size = New Size(padSize, padSize)
            Me.ultraMonthViewMulti1.MonthPadding = padding
        Else
            Me.ultraMonthViewMulti1.MonthPadding = New Size(2, 2)
        End If

    End Sub
using Infragistics.Win;
using Infragistics.Win.UltraWinSchedule;
using Infragistics.Win.UltraWinSchedule.MonthViewMulti;

		private void SetupMonthOrientation()
		{

			//	If there is only one month (or less) visible, the property
			//	setting is not applicable, so return
			if ( this.ultraMonthViewMulti1.VisibleMonths.Count <= 1 )
				return;

			//	If there are 6 or more months being displayed, set the orientation
			//	to DownThenAcross, otherwise to AcrossThenDown
			if ( this.ultraMonthViewMulti1.VisibleMonths.Count >= 6 )
				this.ultraMonthViewMulti1.MonthOrientation = MonthOrientation.DownThenAcross;
			else
				this.ultraMonthViewMulti1.MonthOrientation = MonthOrientation.AcrossThenDown;

			//	Set the MonthPadding to be proportional to the number of
			//	months being displayed by the control
			int numberOfMonths = this.ultraMonthViewMulti1.CalendarInfo.MonthsOfYear.Count;
			if ( this.ultraMonthViewMulti1.VisibleMonths.Count <= numberOfMonths )
			{
				int padSize = numberOfMonths - this.ultraMonthViewMulti1.VisibleMonths.Count;
				Size padding = new Size( padSize, padSize );
				this.ultraMonthViewMulti1.MonthPadding = padding;
			}
			else
				this.ultraMonthViewMulti1.MonthPadding = new Size( 2, 2 );

		}
参照