Spread Windows Forms 6.0 Product Documentation
NonEmptyColumnCount Property
See Also  Example Support Options
FarPoint.Win.Spread Assembly > FarPoint.Win.Spread.Model Namespace > DefaultSheetDataModel Class : NonEmptyColumnCount Property


Glossary Item Box

Gets the number of columns in the model containing data (bound or unbound).

Syntax

Visual Basic (Declaration) 
Public Overrides ReadOnly Property NonEmptyColumnCount As Integer
Visual Basic (Usage)Copy Code
Dim instance As DefaultSheetDataModel
Dim value As Integer
 
value = instance.NonEmptyColumnCount
C# 
public override int NonEmptyColumnCount {get;}

Property Value

Integer number of non-empty columns

Example

Visual BasicCopy Code
Dim strArray() As String = {"Ronnie", "Jack", "Lori", "Max", "Tricky"}
Dim dataModel As New FarPoint.Win.Spread.Model.DefaultSheetDataModel(5, 5)
Dim i, j As Integer
dataModel.DataSource = strArray
FpSpread1.ActiveSheet.Models.Data = dataModel
i = dataModel.NonEmptyColumnCount
j = dataModel.NonEmptyRowCount
ListBox1.Items.AddRange(New Object() {i.ToString(), j.ToString()})
C#Copy Code
string[] strArray = new string[5] {"Ronnie", "Jack", "Lori", "Max", "Tricky"};
int i, j;
FarPoint.Win.Spread.Model.DefaultSheetDataModel dataModel = new FarPoint.Win.Spread.Model.DefaultSheetDataModel(8, 8);
dataModel.DataSource = strArray;
fpSpread1.ActiveSheet.Models.Data = dataModel;
i = dataModel.NonEmptyColumnCount;
j = dataModel.NonEmptyRowCount;
listBox1.Items.AddRange(new object[] {i.ToString(), j.ToString()});

Requirements

Target Platforms: 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

© 2002-2012 ComponentOne, a division of GrapeCity. All Rights Reserved.