WebClient, DownloadFile, OpenRead Does not retrive last modify file

  • Thread starter Thread starter Harvey Triana
  • Start date Start date
H

Harvey Triana

Hi-

I am using...

WebClient Client = new WebClient ();
Client.DownloadFile(url, filename);
Or
Stream strm = Client.OpenRead (url);



But, the stream or file download, is not updated, several calls to url
retrive the same file. The file behind url is update each two seconds.



- How recover the most recent version of the file, in each call of
WebClient?




regards,

<ht />
 
You have a caching problem.

do you have a proxy server between your computer and the server? Usually
they will cache files and return the same file for every request.

Nothing you can do about it except buying bottle of whisky and go to admins
of that proxy :)

George.
 
This trap works!
Stream r = wc.OpenRead(Url + "?t="+ DateTime.Now.Ticks.ToString());

Thanks
 
Back
Top