Solved

Is it possible for only children of a treeview to have checkboxes?

Posted on 2002-07-22
7
169 Views
Last Modified: 2010-05-18
Code example please...
0
Comment
Question by:jackjeckyl
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
  • 2
7 Comments
 
LVL 70

Accepted Solution

by:
Éric Moreau earned 50 total points
ID: 7170570
I have done it in the past (using VB5 - there were no checkbox at this time). You have to use images and toggle it yourself.
0
 
LVL 46

Expert Comment

by:aikimark
ID: 7170983
1. you will need to set the treeview properties so that each node can display an image.
2. add an imagelist control to your form
3. add two pictures to the imagelist's picture collection.  One picture will be a square.  The other picture will be a square with a check.
4. When you add a child node, set the image index = empty-square picture index.
5. When the user double clicks the node, change the image index of the node = checked picture index.
0
 

Author Comment

by:jackjeckyl
ID: 7172980
Good idea, but not what I wanted.  Thanks.
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 70

Expert Comment

by:Éric Moreau
ID: 7173038
What do you want?
0
 
LVL 46

Expert Comment

by:aikimark
ID: 7173235
jackjeckyl,

You've accepted emoreau's comment as the solution to your problem, yet your most recent comment indicates that this is not an acceptable solution.  What more do you need?

emoreau described it. I detailed it.  It's up to you to do it (now).
0
 

Author Comment

by:jackjeckyl
ID: 7175446

I accepted the comment meaning thats what I'd pursue thinking you can't have just straight checkboxes in children.  I wanted true checkboxes, not pictures of checkboxes.  As to follow up, how am I supposed to change all the children to "checked boxes" if someone clicks on the parent and changes that image to a checkbox?  In other words, If you change a parent to a checked box image, all the children have to have checked box images...
0
 

Author Comment

by:jackjeckyl
ID: 7175553
Never mind, I got it.
0

Featured Post

[Live Webinar] The Cloud Skills Gap

As Cloud technologies come of age, business leaders grapple with the impact it has on their team's skills and the gap associated with the use of a cloud platform.

Join experts from 451 Research and Concerto Cloud Services on July 27th where we will examine fact and fiction.

Question has a verified solution.

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

Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
Introduction While answering a recent question about filtering a custom class collection, I realized that this could be accomplished with very little code by using the ScriptControl (SC) library.  This article will introduce you to the SC library a…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
Suggested Courses
Course of the Month7 days, 13 hours left to enroll

632 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