ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Help / WLanguage / WLanguage functions / Controls, pages and windows / TreeView functions
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Others
Stored procedures
Finds an element (leaf or node) in a TreeView control and returns its path.
Example
// Find the element whose identifier is "1" in the "TREE_CustomerTreeView" TreeView control
// Remark: all the elements of the TreeView control are taken into account
ResPath = TreeFind(TREE_CustomerTreeView, 1)
// Find the element whose identifier is "1" in the "TREE_CustomerTreeView" TreeView control
// Search from the root of the TreeView control and only on the leaves
ResPath = TreeFind(TREE_CustomerTreeView, 1, Null, tvLeaf)
Syntax
<Result> = TreeFind(<TreeView control> , <Element to find> [, <Path of source element> [, <Options>]])
<Result>: Character string
  • Path of element found. This string can contain specific control characters. This string can be used in all the functions that manage TreeView controls. This path has the following format:
    "<Root name>" + TAB + ["<Name of 1st node>" + TAB + ...
    ["<Name of 2nd node>" + TAB + [...]]]"<Leaf name>"
  • Empty string ("") if no element corresponds to the search.
<TreeView control>: Control name
Name of the TreeView control to be used.
<Element to find>: Character string or integer
Identifier of element to find. This identifier must be identical to the one used in TreeAdd, TreeInsert or TreeModify.
<Path of source element>: Optional character string
Path of source element for the search in the TreeView control. If this parameter is not specified or if it corresponds to the Null constant, the search is performed from the root of TreeView control.
<Options>: Optional constant (or combination of constants)
Specifies the search characteristics:
tvLeafSearch performed on the leaves of TreeView control.
tvNodeSearch performed on the nodes of TreeView control.
tvOneLevelSearch performed on a single level of tree structure (the elements found below the source branch are ignored). The search is performed on the child elements of source element.

By default, the search is performed with tvLeaf + tvNode (all elements found in the TreeView control are browsed).
Component: wd290obj.dll
Minimum version required
  • Version 11
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 05/26/2022

Send a report | Local help