Results 1 to 3 of 3

Thread: FTP Progress Bar

  1. #1

    Thread Starter
    New Member
    Join Date
    Jan 2000
    Posts
    1

    Post

    I have made a VB program that FTPs a single file to a server using the inet control. However, I need a way to show the progress of this file as it uploads because the file size is usually over 2 Mgs and I upload over a modem. How do I make a progress bar that will show how much has been transfered?

  2. #2
    Lively Member
    Join Date
    Jan 1999
    Location
    Karjalohja, Finland
    Posts
    123

    Post

    I'm using Progress Bar this way:

    Public Sub FtpGetFile()

    Form1.Inet.Execute , "GET " & GetFile & " " & App.Path & "\" & GetFile

    FileTransfer

    End Sub

    Public Sub FileTransfer()

    'ProgressBar Max Value = 35000
    Form1.ProgressBar1.Value = 0.05

    Do While Form1.Inet.StillExecuting

    If Form1.ProgressBar1.Value < Form1.ProgressBar1.Max - 1 Then

    Form1.ProgressBar1.Value = Form1.ProgressBar1.Value + 0.05

    End If

    DoEvents

    Loop

    Form1.ProgressBar1.Value = Form1.ProgressBar1.Max

    End Sub

    - Dj4

  3. #3
    Guest

    Post

    Simple awnser: You can't get that progressbar.

    Hard awnser: it is possible to make your own upload routine, FTP opens a specific port and uploads the file to there(atleast it does so in binary mode.). When it is finished uploading it cloeses the port.

    The way to make a progress bar is to make this yourself(This aint an easy thing to do).


    ------------------

    Vincent van den Braken
    EMail: [email protected]
    ICQ: 15440110
    Homepage: http://www.azzmodan.demon.nl




Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width