DeleteUrlCacheEntryA function (wininet.h)

Removes the file associated with the source name from the cache, if the file exists.


BOOL DeleteUrlCacheEntryA(
  [in] LPCSTR lpszUrlName


[in] lpszUrlName

Pointer to a string that contains the name of the source that corresponds to the cache entry.

Return value

Returns TRUE if successful, or FALSE otherwise. To get extended error information, call GetLastError. Possible error values include the following.

Return code Description
The file is locked or in use. The entry is marked and deleted when the file is unlocked.
The file is not in the cache.


Note  WinINet does not support server implementations. In addition, it should not be used from a service. For server implementations or services use Microsoft Windows HTTP Services (WinHTTP).


The wininet.h header defines DeleteUrlCacheEntry as an alias which automatically selects the ANSI or Unicode version of this function based on the definition of the UNICODE preprocessor constant. Mixing usage of the encoding-neutral alias with code that not encoding-neutral can lead to mismatches that result in compilation or runtime errors. For more information, see Conventions for Function Prototypes.


Requirement Value
Minimum supported client Windows 2000 Professional [desktop apps only]
Minimum supported server Windows 2000 Server [desktop apps only]
Target Platform Windows
Header wininet.h
Library Wininet.lib
DLL Wininet.dll

See also


WinINet Functions