WebClient DownloadString keeping connection open (VB.NET) -


I am using a WebClient object and method download string to obtain some information from a site. The issue I am encountering is the server that runs on this program, which is closed only in 80, while the inital is open for a short time after connection. This means, if the site takes a small amount of time to get data and send it back, then it works correctly if it takes a few minutes to get data and to send it back, it will fail.

Is it possible to keep the connection open?

Or alternatively, is it possible to use a separate port for webcorts?

Thanks

  Using WC as a new webclick httpAuthentication then WC.Credentials = New Network Credentials (Me.httpUsername, Me.httpPassword) End if Dim String = WC as response. Using downloading (Me.uploadUrl) ending  


Comments

Popular posts from this blog

import - Python ImportError: No module named wmi -

Editing Python Class in Shell and SQLAlchemy -

c# - MySQL Parameterized Select Query joining tables issue -