标签:box name end lib gre private entry 清除缓存 log
Private Declare Function URLDownloadToFile Lib "urlmon" Alias "URLDownloadToFileA" (ByVal pCaller As Long, ByVal szURL As String, ByVal szFileName As String, ByVal dwReserved As Long, ByVal lpfnCB As Long) As Long Public Declare Function DeleteUrlCacheEntry Lib "wininet" Alias "DeleteUrlCacheEntryA" (ByVal lpszUrlName As String) As Long Sub DownloadImage(ByVal ImageUrl As String, ByVal ImagePath As String) Dim lngRetVal As Long lngRetVal = URLDownloadToFile(0, ImageUrl, ImagePath, 0, 0) If lngRetVal = 0 Then DeleteUrlCacheEntry ImageUrl ‘清除缓存 ‘MsgBox "成功" Else ‘MsgBox "失败" End If End Sub
标签:box name end lib gre private entry 清除缓存 log
原文地址:http://www.cnblogs.com/nextseven/p/7291766.html