Solved

How to make checkboxes invisible for the Treeview Root node

Posted on 2010-08-15
4
607 Views
Last Modified: 2013-11-29
I have a form with a tree view control in it. It has 4 levels. I would like to have the checkboxes visible only for the 3rd and 4th level.
How to make the checkboxes invisible for the Root node and the 1st level?

FYI: To make the checkboxes visible, I just set the Tree view checkboxes property to TRUE.
0
Comment
Question by:Murugesh Perumal
  • 2
4 Comments
 
LVL 4

Expert Comment

by:Audhi203
ID: 33443565
Access till the nodes/levels you want to make checkboxes invisibile and set <ctrl>.Visible = false based on your if-else conditions
0
 
LVL 47

Accepted Solution

by:
Dale Fye (Access MVP) earned 125 total points
ID: 33553487
I'm not sure that there is a way to do this.  I've been using the treeview for quite a while and I believe that the checkbox property applies to the entire tree.  I cannot recall ever seeing a tree that has checkboxes at one level and not another.

However, you could use the treeview controls Check event to determine the level that was checked (I usually store that value in the nodes Tag property as I build the tree).  If the level was 1 or 2, you could display a message advising the user that checking those levels has no effect.  Then set the nodes Checked Property to false.
0
 

Author Closing Comment

by:Murugesh Perumal
ID: 33733080
I agree that there is no straight away method to make the checkboxes invisible only for certain levels.

Checking the checkboxes - validations can be done
0
 
LVL 47

Expert Comment

by:Dale Fye (Access MVP)
ID: 33733855
A "C",  what about the answer deserved a "C"?


Was it inaccurate? incomplete?

The fact that you cannot do what you wanted to do is no reason for a "C".
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

In Debugging – Part 1, you learned the basics of the debugging process. You learned how to avoid bugs, as well as how to utilize the Immediate window in the debugging process. This article takes things to the next level by showing you how you can us…
I see at least one EE question a week that pertains to using temporary tables in MS Access.  But surprisingly, I was unable to find a single article devoted solely to this topic. I don’t intend to describe all of the uses of temporary tables in t…
Basics of query design. Shows you how to construct a simple query by adding tables, perform joins, defining output columns, perform sorting, and apply criteria.
In Microsoft Access, learn the trick to repeating sub-report headings at the top of each page. The problem with sub-reports and headings: Add a dummy group to the sub report using the expression =1: Set the “Repeat Section” property of the dummy…

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now