Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / General / February 2008

Tip: Looking for answers? Try searching our database.

WebClient, DownloadFile, OpenRead Does not retrive last modify file

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Harvey Triana - 08 Feb 2008 18:02 GMT
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 />
Harvey Triana - 08 Feb 2008 18:10 GMT
Disculpas, este posting no era para este grupo en español.. Los afanes.

> Hi-
>
[quoted text clipped - 14 lines]
>
> <ht />
George Ter-Saakov - 08 Feb 2008 18:15 GMT
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.

> Hi-
>
[quoted text clipped - 14 lines]
>
> <ht />
Harvey Triana - 08 Feb 2008 18:40 GMT
This trap works!
Stream r = wc.OpenRead(Url + "?t="+ DateTime.Now.Ticks.ToString());

Thanks

> You have a caching problem.
>
[quoted text clipped - 24 lines]
>>
>> <ht />
George Ter-Saakov - 08 Feb 2008 18:46 GMT
You right, forgot about that trick although using it myself :)

George.

> This trap works!
> Stream r = wc.OpenRead(Url + "?t="+ DateTime.Now.Ticks.ToString());
[quoted text clipped - 29 lines]
>>>
>>> <ht />

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.