?
Solved

Lock treeview update

Posted on 2006-07-18
1
Medium Priority
?
258 Views
Last Modified: 2006-11-18
Hi Experts,

I would like to lock a treeview from updating for a few lines of code,

What i mean is:

'Lock
If IsExpanded = True Then
        Nd.Collapse()
    Else
        Nd.Expand()
End If
'Unlock

How easy is this to accomplish?

Cheers,

Tom
0
Comment
Question by:TommyTwoPints
[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
1 Comment
 
LVL 5

Accepted Solution

by:
mydasx earned 2000 total points
ID: 17134424
use synclock.  easy as greasy!

Sub MonkeyBusiness()
    SyncLock Me.treeView1
         'treeview bidness goes here
    End SyncLock
End Sub
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

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

It’s quite interesting for me as I worked with Excel using vb.net for some time. Here are some topics which I know want to share with others whom this might help. First of all if you are working with Excel then you need to Download the Following …
Calculating holidays and working days is a function that is often needed yet it is not one found within the Framework. This article presents one approach to building a working-day calculator for use in .NET.
This is my first video review of Microsoft Bookings, I will be doing a part two with a bit more information, but wanted to get this out to you folks.
How to fix incompatible JVM issue while installing Eclipse While installing Eclipse in windows, got one error like above and unable to proceed with the installation. This video describes how to successfully install Eclipse. How to solve incompa…
Suggested Courses
Course of the Month8 days, 16 hours left to enroll

764 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