Solved

Playing animated GIF while populating Treeview.  Please Help!

Posted on 2004-04-28
2
737 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
[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
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

Independent Software Vendors: 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!

Question has a verified solution.

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

There are many ways to remove duplicate entries in an SQL or Access database. Most make you temporarily insert an ID field, make a temp table and copy data back and forth, and/or are slow. Here is an easy way in VB6 using ADO to remove duplicate row…
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…
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…
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