Simple event question

Bonekrusher

Active member
Joined
Jul 4, 2007
Messages
38
Programming Experience
1-3
Hi,

I have a very simple question. I have an button click event that performs an ftp connection. This works great. I want an animated gif to display durring the process. So i put the following for the 1st step of the event:

VB.NET:
Me.PictureBox1.Visible = True

But the gif doesnt become visable until after all code has been executed.

How do I get this to be visiable at the beggining of the event and back to Me.PictureBox1.Visible = false at the end of the event?

Thanks!
 
Hi thanks for the quik response.

I tried your suggestion, but no luck. I placed your code at the start of the event.

Where should I put it?

Thanks?
 
if you have a do loop or something

VB.NET:
do

''your code here
application.doevents

loop

it stops your code having exclusive priority, and frees resources to update display events
 
Back
Top