Skip to main content

TcxCustomTreeList.FindNodeByText(string,TcxTreeListColumn,TcxTreeListNode,Boolean,Boolean,Boolean,TcxTreeListFindMode,TcxTreeListLikeParams,Boolean) Method

Searches for the first node that contains the specified text.

Declaration

function FindNodeByText(const AText: string; AColumn: TcxTreeListColumn; AStartNode: TcxTreeListNode = nil; AExpandedOnly: Boolean = False; AForward: Boolean = True; ACaseSensitive: Boolean = True; AMode: TcxTreeListFindMode = tlfmNormal; ALikeParams: TcxTreeListLikeParams = nil; AIgnoreStartNode: Boolean = False): TcxTreeListNode;

Parameters

Name Type
AText string
AColumn TcxTreeListColumn
AStartNode TcxTreeListNode
AExpandedOnly Boolean
AForward Boolean
ACaseSensitive Boolean
AMode TcxTreeListFindMode
ALikeParams TcxTreeListLikeParams
AIgnoreStartNode Boolean

Returns

Type
TcxTreeListNode

Remarks

If the match was successful, the FindNodeByText function returns the first found node and stops the search. If the match is not found, the function returns nil.

AText specifies the text by which a node is to be located.

AColumn specifies the column in which the search is to be performed. Pass nil as this parameter to search in all columns contained in the tree list.

AStartNode specifies the node from which the search starts.

AExpandedOnly specifies whether the expanded child nodes of the expanded parents are involved in the search.

AForward specifies the search direction. Set AForward to True, to search forward. Otherwise, a backward search is performed.

ACaseSensitive specifies whether the search is case sensitive. Set ACaseSensitive to True, to perform a case-sensitive search.

AMode specifies the search mode. Values include:

Value Description
tlfmNormal Searches for any entries of AText in a data cell‘s content.
tlfmLike Performs a pattern search of AText.
tlfmExact Performs exact search of AText.

For instance, in tlfmNormal mode for the ‘ar’ search string, successive calls to the function will return the following strings: Earth, Mars, Elara, Carme, Ariel, Larissa, Charon.

In tlfmLike mode, for the ‘%a_u%’ search pattern, successive calls to the function will return the following strings: Saturn, Janus, Enceladus, Uranus.

For detailed information, refer to the ExpressQuantumTreeList Features demo (module Search).

ALikeParams specifies wildcards used in the pattern search (AMode is tlfmLike).

AIgnoreStartNode specifies whether to ignore a node that matches ANode. Set AIgnoreStartNode to True, to ignore the node.

See Also