AYUDA EN LÍNEA
 WINDEVWEBDEV Y WINDEV MOBILE

Este contenido se ha traducido automáticamente.  Haga clic aquí  para ver la versión en inglés.
Ayuda / WLanguage / Funciones WLanguage / Controles, páginas y ventanas / Funciones TreeView
  • Handling the duplicate elements in a TreeView control
  • When to use TreeID?
WINDEV
WindowsLinuxJavaReportes y ConsultasCódigo de Usuario (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Código Navegador
WINDEV Mobile
AndroidWidget Android iPhone/iPadIOS WidgetApple WatchMac Catalyst
Otros
Procedimientos almacenados
Allows you to build the path of the elements found in a TreeView control by differentiating the duplicates. This function can be used in all the functions for handling the elements found in a TreeView control.
Ejemplo
ResultTreeView is boolean
ResultTreeView = TreeAdd(TREE_TreeView1, "Root" + TAB + "Leaf", tvDefault, tvDefault, "Unique leaf ID")
ResultTreeView = TreeAdd(TREE_TreeView1, "Root" + TAB + "Leaf", tvDefault, tvDefault, "Unique leaf 2 ID", tvAcceptDuplicate)
// Delete the 2nd duplicate
TreeDelete(TREE_TreeView1, "Root" + TAB + "Leaf" + TreeID("Unique leaf 2 ID"))
Sintaxis
<Result> = TreeID(<Identifier>)
<Result>: Character string
Control string that must be added to the name of the element when it is handled by the TreeView control functions.
<Identifier>: Character string
Element identifier. This identifier is used to build the control string of the element. This identifier must be identical to the one used in TreeAdd, TreeInsert or TreeModify.
Observaciones

Handling the duplicate elements in a TreeView control

The management of duplicates in TreeView controls is based on the management of identifiers. Each section of the path of a TreeView control element can be associated with an identifier. This association is performed by TreeAdd, TreeInsert or TreeModify.
TreeID handles duplicates by identifier. Simply add the corresponding control string to the desired path element.
Example:
TreeDelete(TREE_TreeView1, "Root" + TAB + "Leaf" + TreeID("Unique leaf 2 ID"))
In this example, there are two "Leaf" elements. TreeID identified the element to be deleted.

When to use TreeID?

TreeID can be used:
  • in all the syntaxes of the TreeView control functions, as soon as the path of a duplicate element must be specified.
  • in the <TreeView control name>[<Element path>] syntax, which is used to easily manipulate an element of a TreeView control.
The element used is the one whose path and identifier match.
Remark: It is possible to specify an identifier for each part of an element's path.
Componente: wd300obj.dll
Versión mínima requerida
  • Versión 9
Esta página también está disponible para…
Comentarios
Haga clic en [Agregar] para publicar un comentario

Última modificación: 30/09/2024

Señalar un error o enviar una sugerencia | Ayuda local