dcsimg
Results 1 to 23 of 23

Threaded View

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Jul 2015
    Posts
    17

    Resolved [RESOLVED] WebClient downloads only 1 GB, then fails & Round number to 1 decimal place

    Hi! I wanna download 2 GB file with WebClient, but after it downloads 1 GB it stops without any error.
    Thanks for any help!

    Code:
    Sub download(ByVal file As String, ByVal uri As String, ByVal ffile As String)
            la_dl.Text = file
            SW = Stopwatch.StartNew
            Dim client As WebClient = New WebClient
            AddHandler client.DownloadProgressChanged, AddressOf download_change
            AddHandler client.DownloadFileCompleted, AddressOf client_DownloadCompleted
            If My.Computer.FileSystem.DirectoryExists(Application.StartupPath & "/dl") = False Then
                My.Computer.FileSystem.CreateDirectory(Application.StartupPath & "/dl")
            End If
            client.DownloadFileAsync(New Uri(uri), Application.StartupPath & "/dl/" & ffile)
        End Sub
    Last edited by henryolik; Dec 29th, 2017 at 05:01 AM. Reason: Deleted second issue

Posting Permissions

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



Featured


Click Here to Expand Forum to Full Width


×
We have made updates to our Privacy Policy to reflect the implementation of the General Data Protection Regulation.