Solved

treenode images

Posted on 2009-04-08
2
337 Views
Last Modified: 2013-12-26
I'm dynamically creating nodes on my form based upon 3 different conditions.
Consider it Best, Good, Bad for example.
I 'only' will want an associated icon/image depending on those values.
So far, so good.
However, I've noticed that when I assign the imageindex correctly, there are two other states to be concerned with - dropdown state and selected state.  
How can I simply ignore those and use the imageindex property alone?
Surely I don't have to assign all 3 do I?
Dim tn As New TreeNode(MyData)

tn.ImageIndex = 2 'Bad

Open in new window

0
Comment
Question by:sirbounty
2 Comments
 
LVL 27

Accepted Solution

by:
VBRocks earned 300 total points
ID: 24100101
Set them to be the same.

0
 
LVL 67

Author Comment

by:sirbounty
ID: 24100330
Hmm - then can I override the instance creation to pass that index value and assign all 3 there?
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Background What I'm presenting in this article is the result of 2 conditions in my work area: We have a SQL Server production environment but no development or test environment; andWe have an MS Access front end using tables in SQL Server but we a…
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
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…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…

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

13 Experts available now in Live!

Get 1:1 Help Now