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

Find Panel

  • 4 minutes to read

The built-in Find Panel provides an easy way of searching against visible grid items (records in the VGridControl, and property names in the PropertyGridControl). Displayed above the grid, the panel contains a search box and control buttons.

VGrid-FindPanel

When searching, the grid filters its items displaying only those that match the entered search string. If you clear the search string and perform the search again, the grid will display all items.

Search Syntax

In its simplest form, a search criterion consists of a single word. If you wish 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.

In the VGridControl, you can search against a specific row (field) by preceding a search string with the row’s display name plus a colon character.

RowDisplayName:SearchString

Instead of the complete name, it is possible to partially specify the display name, using the initial characters of a row’s display name. A search will be performed against the first row whose display name starts with the specified substring. If you want to search against a row whose display caption contains space characters, specify the row’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 row, 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 row 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 only display 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.
check register Dave Selects records that contain “check” OR “register” OR “Dave”.
"check register" Selects records that contain “check register”.
screen +"Richard Fisher" Selects records that contain both “screen” AND “Richard Fisher”.
data +entry -mark Selects records that contain both “data” AND “entry”, excluding records that contain “mark”.
menu mask -file Selects records that contain “menu” OR “mask”, excluding records that contain “file”.
Product:Tofu Seattle Only applies to the VGridControl. Selects records that contain “Tofu” in the row that starts with “Product”, AND contain “Seattle” in any search row.
From:Roller Subj:"currency mask" Only applies to the VGridControl. Selects records that contain “Roller” in the row that starts with “From”, AND contain “currency mask” in the row that starts with “Subj”.
import -From:Steve Only applies to the VGridControl. Selects records that contain “import” in any search row, excluding records that contain “Steve” in the row that starts with “From”.

Note

Searches performed using the Find Panel are not case-sensitive.

Find Panel Options

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

Visibility

If the VGridOptionsFind.Visibility option is set to Default, an end-user can invoke the Find Panel by pressing CTRL+F. Make sure that no cell editor is open before invoking the Find Panel. Otherwise, the shortcut will be intercepted by the in-place editor. Set this property to Always in order to always display the Find Panel and prevent it from being hidden by an end-user. Set this property to Never to permanently hide the Find Panel.

The VGridControlBase.ShowFindPanel/VGridControlBase.HideFindPanel methods and the VGridControlBase.FindPanelVisible property allow you to specify the Find Panel’s visibility.

Searching

VGridOptionsFind.FindMode - Specifies if a data search starts automatically or if it must be started manually (by clicking the Find button or by pressing the Enter key).

VGridOptionsFind.FindDelay - Specifies the wait time (in milliseconds) before a data search is initiated (in automatic find mode).

Search String

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

Search Rows/Fields

Only applies to the VGridControl.

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

Search Result

VGridOptionsFind.HighlightFindResults - Specifies whether or not search strings within the matched records 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 grid’s data area.