Solved

Playing animated GIF while populating Treeview.  Please Help!

Posted on 2004-04-28
2
730 Views
Last Modified: 2013-12-25
I am populating a Treeview in a program and it takes a long time.  I want to play a .GIF animation while it is loading.  I have the GIF loaded into a WebBrowser.  I can only get the first frame of the animation to play while the loop is running to fill the Treeview.  The animation will play after the Treeview is filled.  How do I run the loop AND have the animation play at the same time?

I am using VB 6.0 sp5.  Let me know if you need any other info!

Thanks!!
0
Comment
Question by:jtminton
2 Comments
 
LVL 9

Accepted Solution

by:
p_sie earned 500 total points
ID: 10940139
Did you place DoEvents in the procedure where you are filling the Treeview?

Example

For i = 1 to 1000
    Tree.nodes.add ....
    DoEvents
Next

Doevents will let other processes get processor time!
0
 

Author Comment

by:jtminton
ID: 10942238
Thanks, I should have known that!  It worked, but it made my tree load 2.5 times slower.  Oh well.
0

Featured Post

Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

Join & Write a Comment

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
When designing a form there are several BorderStyles to choose from, all of which can be classified as either 'Fixed' or 'Sizable' and I'd guess that 'Fixed Single' or one of the other fixed types is the most popular choice. I assume it's the most p…
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…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

707 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

17 Experts available now in Live!

Get 1:1 Help Now