Skip to main content
A newer version of this page is available. .

Find Panel

  • 5 minutes to read

The built-in Find Panel provides an easy way to search against multiple columns. It is displayed above the Column Header Panel. The Find Panel contains a search box and control buttons.

Find Panel TreeList

When searching, a Tree List control highlights records that contain the required text. If Filtering is enabled, the Tree List will hide records that do not match the search criteria.

By default, a child node that meets a search criterion is shown only if all of its parent nodes meet that criterion. This behavior can be changed by setting the TreeListOptionsFilter.FilterMode property to FilterMode.Smart.

Search Syntax

In its simplest form, a search criterion consists of a single word. If you want to search for a string containing a space character, specify this string in quotation marks. Without quotation marks, words separated by the space character are treated as individual conditions.

You can search against a specific column by preceding a search string with the column’s display name plus a colon character.

ColumnDisplayName:SearchString

Instead of the complete name, it is possible to partially specify the display name, using the initial characters of a column’s display name. A search will be performed against the first column whose display name starts with the specified substring. If you want to search against a column whose display caption contains space characters, specify the column’s display caption in quotation marks.

If the search string contains multiple conditions separated by space characters, and at least one condition defines a search against a specific column, only records that match all of these conditions are shown (i.e., the conditions are combined by the AND logical operator). If there is no column specification, records that match at least one of these conditions are shown (i.e., the conditions are combined by the OR logical operator).

Precede a condition with “+” to display only records that match this condition. The “+” specifier allows you to implement the logical AND operator. There should be no space character between the “+” sign and the condition.

Precede a condition with “-“ to exclude records that match this condition from the result set. There should be no space between the “-“ sign and the condition.

Examples

Search Criteria Description
register Selects records that contain the “register” string in any search column.
check register Dave Selects records that contain either “check” OR “register” OR “Dave” strings in any search column.
"check register" Selects records that contain “check register” in any search column.
screen +"Richard Fisher" Selects records that contain both “screen” AND “Richard Fisher” in search columns.
Product:Tofu Seattle Selects records that contain “Tofu” in the column that starts with “Product”, AND also contain “Seattle” in any search column.
data +entry -mark Selects records that contain both “data” AND “entry” in search columns, excluding records that contain “mark”.
menu mask -file Selects records that contain “menu” OR “mask”, excluding records that contain “file”.
From:Roller Subj:"currency mask" Selects records that contain “Roller” in the column that starts with “From”, AND also contain “currency mask” in the column that starts with “Subj”.
import -From:Steve Selects records that contain “import” in any search column, excluding records that contain “Steve” in the column that starts with “From”.

Note

Searches performed using a Find Panel are case insensitive.

Find Panel Options

The following table lists the main properties affecting the Find Panel’s behavior and appearance.

Visibility

If the TreeListOptionsFind.AllowFindPanel option is enabled, an end-user can invoke a Find Panel by pressing CTRL+F. Ensure that no cell editor is open before invoking the Find Panel. Otherwise, the shortcut will be intercepted by the in-place editor.

TreeListOptionsFind.AlwaysVisible - Set this property to true in order to always display the Find Panel and prevent it from being hidden by an end-user.

The TreeList.ShowFindPanel/TreeList.HideFindPanel methods allow you to manually display/hide the control.

Searching

TreeListOptionsFind.FindMode property - Specifies whether data searching starts automatically or if it must be started manually (by clicking the Find button or pressing the ENTER key).

TreeListOptionsFind.FindDelay property - Specifies the amount of time in milliseconds, after which a data search is initiated (in automatic find mode).

TreeList.ApplyFindFilter method - Allows you to start a search manually in code.

TreeListOptionsFilter.FilterMode property - Specifies whether or not to display the child nodes of parents that do not match the search criterion.

Search String

Searches are performed against a string specified by an end-user in a Find Panel’s edit box (TreeList.FindFilterText).

The TreeList.ApplyFindFilter method allows you to specify a search string in code.

Search Columns/Fields

TreeListOptionsFind.FindFilterColumns. By default, this property is set to “*”. In this instance, searches are performed against all visible columns. To search against specific columns, assign the corresponding field names to the FindFilterColumns property, delimiting them with the “;” character.

Search Result

TreeListOptionsFind.HighlightFindResults property - Specifies whether or not the search strings within the search results should be highlighted.

Keyboard Operations

CTRL+F - Invokes the Find Panel.

ESC - Clears the search box. If the search box is empty, pressing ESC closes the Find Panel.

DOWN ARROW - Moves focus from the Find Panel to the TreeList’s data area.