Fog Creek Software
Discussion Board

Welcome! and rules

Joel on Software

Caching in a Windows Form app

I have a windows form app that uses HttpWebRequest to download jpgs from the web.  I assumed at first that the images were cached in the normal IE cache, but now I think that is not the case.  Can anyone verify that?

If it's not, what are my options?  I've looked at System.Web.HttpRuntime.Cache, but I'm not clear if that is persistent or not [ie, does the cache get cleared when my app exits?].  Do I need to write my own cache logic to achieve persistence? 

What about using the old XmlHttp - I believe that did use the IE cache?


Thursday, November 25, 2004

You said you are using a Windows Form based application to download the images. In that case, the IE cache will not contain these images. In case of web based applications, ASP.NET provides you enough caching features to cache the images. In case of Windows Forms App, AFAIK, you have to implement your own caching logic.

This link might help you in deciding your caching implementation. Specifically, read the secion Caching Images.

Hope this helps.


Wednesday, January 5, 2005

*  Recent Topics

*  Fog Creek Home