tags:

views:

43

answers:

2

I have tried using the My.Computer.Network.DownloadFile method but unfortunately it is slow. Executing the simple command below takes ~5-10 secs, which I would say is a lot longer than expected for downloading a 9 kb file.

`My.Computer.Network.DownloadFile("http://www.google.dk", "j:\temp\test.html")` 

I am connecting via a high-speed connection (>10GB) from a Win7 machine. Do anyone know of any explanations for this behavior?

Hope that you can help me out with this. Kristoffer

A: 

It could be the overhead in making the connection that makes it seems slow when it's such a small file, maybe for a bigger file it would be less noticeable.
Also, even if you have a fast connection from you to your ISP, your ISP might have a bad connection to google.dk, and are you the only one using it or could it be congested with other traffic?

I'd suggest trying to download other size files from other locations.

ho1
Thanx i will try it out
A: 

Try using a WebClient:

Using client = New WebClient()
    client.DownloadFile("http://www.google.dk", "j:\temp\test.html")
End Using
Darin Dimitrov