English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

Hi,
I made an activex, that downloads a file to client..I converted cab file with package&deployment wizard, and signed it..
There is an progressbar on the usercontrol(activex control form)..
and set the progressbar value appropriate value while downloading..
I use these lines:
---------------------------------------------------
Do
DoEvents
bData = InetDwn.GetChunk(CHUNK, icByteArray)
DoEvents
If i Mod (downloading_file_all_size / 10) = 0 Then
' I used this line to increase progressbar value every 10 percent
'downloaded
DoEvents
DoEvents
ProgressBar1.Value = ProgressBar1.Value + 1
DoEvents
DoEvents
i = 0
DoEvents
DoEvents
End If
DoEvents
DoEvents
Put #intfile, , bData
i = i + 1
Loop While UBound(bData, 1) > 0
'but progressbar is appeared after all downloading and show %100

HELP!

2007-01-30 20:50:00 · 3 answers · asked by mobildeveloper 1 in Computers & Internet Programming & Design

3 answers

If I understand you correctly, the progress bar only appears after all the processing is finished and it shows 100% instead of updating as the process is ongoing?

I would try refreshing every time you update the progress bar:

ProgressBar1.Value = ProgressBar1.Value + 1
ProgressBar1.Refresh

or perhaps
Form1.Refresh

hope that helps

2007-01-31 02:03:52 · answer #1 · answered by rod 6 · 0 0

I don't think you need all those DoEvents, I never use it with progressbars.
I think your main problem might be that you're setting i to 0 inside the if..else statement.

2007-01-31 07:28:02 · answer #2 · answered by alanprogrock 3 · 0 0

wow

2007-01-30 22:22:57 · answer #3 · answered by Pushpendra Singh Sisodia 6 · 0 0

fedest.com, questions and answers