PFGrid toolkit and controls for .NET Winforms

...Empower your UI with our Winforms and SWT controls!

Filter-Row for Winforms PFGrid.NET

By setting the property ShowFilterRow to true, a filterrow can be displayed below the column-headers.

Filterrow for PFGrid.NET 

The cell-values of the row implicitly call a Column-Filter for a TreeListColumn.

Defining editors for the filterrow

Each TreeListColumn has a property called Editor which defines the Type of the control to edit cells. For the filterrow you sometimes need a different editor than for other rows. In this case you can set the Type for the FilterRow-editor by the property FilterRowEditor of the TreeListColumn-class.

Filtering with cells

The CheckBoxCell for example does not have a cell-editor, it's value can be changed directly with the mouse or with the keyboard (Space, F2, Return). When CheckBoxes are displayed for cells you need a Tri-State-Checkbox to filter the values - because you want to filter for true, false or both.

In this case you can define a CheckBoxColumn and a CheckBoxColumnFilter. The cell that is created for the filterrow automatically appears as TriState CheckBox.

TreeListCheckBoxColumn col = new TreeListCheckBoxColumn();
col.Filter = new CG.Controls.Grid.Filter.CheckBoxColumnFilter(treeListView);
col.Filter.HasUI = false;
col.Filter.FilterMode = CG.Controls.Grid.Filter.EnFiltermode.Filter;
col.AlignCellHorizontal = StringAlignment.Center;
col.AlignHeaderHorizontal = StringAlignment.Center;
col.Width = 60;
col.AllowEdit = false;