Question Example ABL .NET TreeView

Cecil

19+ years progress programming and still learning.
OE 11.7.15 64bit.
OS Windows 10.

Does anybody have any example code of dynamically adding nodes/subnodes to a .NET TreeView.?

My objective is when the user clicks on a node the sibling nodes are dynamically created and the process is repeated each time the user clicks on a sybling node.

Regards
James.
 

Osborne

Active Member
I have some example code of dynamically adding nodes and sub nodes to a .NET TreeView and this is attached.

It does not do exactly what you require as it dynamically adds when first run and not when a node is clicked, but hopefully it gives you some ideas and you can adapt.
 

Attachments

  • orderstreeview.cls
    3.7 KB · Views: 27

Cecil

19+ years progress programming and still learning.
I have some example code of dynamically adding nodes and sub nodes to a .NET TreeView and this is attached.

It does not do exactly what you require as it dynamically adds when first run and not when a node is clicked, but hopefully it gives you some ideas and you can adapt.
This is perfect. This has given me a good start.
 

ppar

New Member
I have some example code of dynamically adding nodes and sub nodes to a .NET TreeView and this is attached.

It does not do exactly what you require as it dynamically adds when first run and not when a node is clicked, but hopefully it gives you some ideas and you can adapt.
As we are getting into .NET technology, we would like to call the above class (orderstreeview.cls), but we need some very short sample code that will make use of that class. This will help us get started. Thanks in advance!
 

Osborne

Active Member
For a quick example connect to the Sports2000 database and run something similar to this:
Code:
/* runorderstreeview.p */
DEFINE VARIABLE oOrderstreeview AS orderstreeview NO-UNDO.

oOrderstreeview = NEW orderstreeview().
oOrderstreeview:Show().
WAIT-FOR System.Windows.Forms.Application:Run(oOrderstreeview).
QUIT.
 
Top