-
I Created an Ftp Program and it works pretty well. All im having trouble with is Adding a progress bar to it. Not to sure how to go about getting the filesize of the file im downloading and how to put it into the progress bar scheme.
Can any one shed a little light on this.
thx all
jre
-
Somebody's got to know this
-
I'm using Progress Bar this way. This is not good but, that works. And I'm using Inet-controls.
Public Sub GetFtpFile()
Inet1.Execute , "GET Test.exe C:\Temp\Test.exe"
FileTransfer
End Sub
Public Sub FileTransfer()
'ProgressBar1.Max = 320000
ProgressBar1.Value = 0.05
Do While Inet1.StillExecuting
If ProgressBar1.Value < ProgressBar1.Max - 1 Then
ProgressBar1.Value = ProgressBar1.Value + 0.05
End If
DoEvents
Loop
ProgressBar1.Value = ProgressBar1.Max
End Sub
AND
File size you can get, this way:
Inet1.Execute , "DIR Test.exe"
Do
DoEvents
Loop While Inet1.StillExecuting