Version

LogicalColumnCount Property

Returns the number of logical columns.
Syntax
'Declaration
 
Public ReadOnly Property LogicalColumnCount As Integer
public int LogicalColumnCount {get;}
Example
The following code sample demonstrates how the LogicalColumnCount and InViewColumnCount properties can be used to determine the percentage of columns that are currently being displayed.

Imports Infragistics.Win
Imports Infragistics.Win.UltraWinSchedule

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click

        '	Get the total number of columns, which equals the number
        '	of owners in the associated CalendarInfo's 'VisibleOwners'
        '	collection, multiplied by the number of selected days.
        Dim totalColumnCount As Int32 = Me.UltraDayView1.LogicalColumnCount

        '	Get the total number of columns that are currently in view
        Dim inViewColumnCount As Int32 = Me.UltraDayView1.InViewColumnCount

        '	Calculate the percentage of columns that are in view
        Dim percentVisible As Double = inViewColumnCount / totalColumnCount

        Debug.WriteLine(percentVisible.ToString("p") + " of the viewable columns are currently in view.")


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

		private void button1_Click(object sender, System.EventArgs e)
		{
			//	Get the total number of columns, which equals the number
			//	of owners in the associated CalendarInfo's 'VisibleOwners'
			//	collection, multiplied by the number of selected days.
			int totalColumnCount = this.ultraDayView1.LogicalColumnCount;

			//	Get the total number of columns that are currently in view
			int inViewColumnCount = this.ultraDayView1.InViewColumnCount;

			//	Calculate the percentage of columns that are in view
			double percentVisible = ((double)inViewColumnCount / (double)totalColumnCount);

			Debug.WriteLine( percentVisible.ToString("p") + " of the viewable columns are currently in view." );

		}
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