ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   VBA: Code to Clear IE Cache (https://www.excelbanter.com/excel-programming/427812-vba-code-clear-ie-cache.html)

CM4@FL[_2_]

VBA: Code to Clear IE Cache
 
Can someone please provide me with the coding to clear my IE cache?

Thanks

RB Smissaert

Code to Clear IE Cache
 
This is one way:

Private Declare Function DeleteUrlCacheEntry Lib "Wininet.dll" _
Alias "DeleteUrlCacheEntryA" _
(ByVal lpszUrlName As String)
As Long

Sub ClearCache(strURL As String)

If DeleteUrlCacheEntry(strURL) = 0 Then
MsgBox "The cached couldn't be cleared, so" & _
vbCrLf & "possibly you won't get the latest.", , _
"clearing cache"
End If

End Sub


Sub test()

ClearCache "http://www.google.co.uk/"

End Sub


RBS



"CM4@FL" wrote in message
...
Can someone please provide me with the coding to clear my IE cache?

Thanks




All times are GMT +1. The time now is 12:22 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com