Gets the count of all
Columns (visible and invisible).
Namespace: Dapfor.Net.UiAssembly: Dapfor.Net (in Dapfor.Net.dll) Version: 2.10.3.24917 (2.10.3.24917)
Syntax
C# |
---|
public int Count { get; } |
Visual Basic |
---|
Public ReadOnly Property Count As Integer
Get |
Visual C++ |
---|
public:
property int Count {
int get ();
} |
F# |
---|
member Count : int with get
|
Property Value
Type:
Int32The count of
Columns.
Examples
| Copy |
---|
public void VisibleColumnsExample(Grid grid)
{
Header header = new Header();
header.Add(new Column("Column1"));
header.Add(new Column("Column2"));
header.Add(new Column("Column3"));
grid.Headers.Add(header);
Console.WriteLine("Visible columns count: {0}", header.VisibleColumns.Count);
header[1].Visible = false;
Console.WriteLine("Columns count: {0}", header.Count);
Console.WriteLine("Visible columns count: {0}", header.VisibleColumns.Count);
header.VisibleColumns[1].VisibleIndex = 0;
foreach (Column column in header.VisibleColumns)
{
Console.WriteLine("Visible column: id = '{0}', index = {1}, visible index = {2}", column.Id, column.Index, column.VisibleIndex);
}
header.VisibleColumns.Clear();
Console.WriteLine("Columns count: {0}", header.Count);
Console.WriteLine("Visible columns count: {0}", header.VisibleColumns.Count);
}
Visible columns count: 3
Columns count: 3
Visible columns count: 2
Visible column: id = 'Column3', index = 2, visible index = 0
Visible column: id = 'Column1', index = 0, visible index = 1
Columns count: 3
Visible columns count: 0 |
See Also