string xmlUrl = "http://myserver.com/xmlfile.xml";
WebClient client = new WebClient();
// prevent file caching by windows
client.CachePolicy = new System.Net.Cache.RequestCachePolicy(
System.Net.Cache.RequestCacheLevel.NoCacheNoStore
);
// read content of file
Stream rssStream = client.OpenRead(xmlUrl);
Использование No Cache No Store.
Edit: Если это не сработает, то попробуйте с WebRequest/WebResponse:
WebRequest request = WebRequest.Create(uri);
// Define a cache policy for this request only.
HttpRequestCachePolicy noCachePolicy = new HttpRequestCachePolicy(HttpRequestCacheLevel.NoCacheNoStore);
request.CachePolicy = noCachePolicy;
WebResponse response = request.GetResponse();
Как вы видите, что они кэшируются? Это просто добавляет заголовок к запросу, он не контролирует то, что сервер отправляет. – Cine