Solved

How to make checkboxes invisible for the Treeview Root node

Posted on 2010-08-15
4
610 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

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I originally created this report in Crystal Reports 2008 where there is an option to underlay sections. I initially came across the problem in Access Reports where I was unable to run my border lines down through the entire page as I was using the P…
Preparing an email is something we should all take special care with – especially when the email is for somebody you may not know very well. The pressures of everyday working life stacked with a hectic office environment can make this a real challen…
In Microsoft Access, learn how to use Dlookup and other domain aggregate functions and one method of specifying a string value within a string. Specify the first argument, which is the expression to be returned: Specify the second argument, which …
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…

820 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