Treeview Questions

F

FBxiii

I have managed to get the treeview control to work using the knowledge base
article but it is very basic.

How do I get it to show the + for expanding each branch and assign different
icons to each selection within the control?

I also need to extend the treeview to show 2 levels rather than 1.

MAIN >
BRANCH 1 >
BRANCH 2

The sections need to be populated by 1 recordset each also (e.g. tblMAIN,
tblBRANCH1, tblBRANCH2)

Can anyone help me?

Steve.
 
R

Rob Parker

To show the + (or -, to shrink the branch) symbol, you must set the Style
property to either 6 or 7. If you want to assign a picture/icon to the
node, you need style 7. You get to these properties by right-clicking on
the control in design mode, then selecting TreeCtl Object - Properties.

The best example I've seen which illustrates the treeview control and its
capabilities is on Alex Dybenko's site. Have a look at
http://www.pointltd.com/Downloads/Details.asp?dlID=36

Helen Feddema's Access Archon page includes an article on using the treeview
control; it's No. 103 in the list at http://www.helenfeddema.com/access.htm

The most comprehensive documentation I've found is on the MSDN site; start
at http://msdn.microsoft.com/library/default.asp and search for treeview.
You should also check for imagelist - it's the easiest way to set up icons
for the nodes.

HTH,

Rob
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top