ReadUrlCacheEntryStream function (wininet.h)

Reads the cached data from a stream that has been opened using the RetrieveUrlCacheEntryStream function.

Syntax

BOOL ReadUrlCacheEntryStream(
  [in]      HANDLE  hUrlCacheStream,
  [in]      DWORD   dwLocation,
  [in, out] LPVOID  lpBuffer,
  [in, out] LPDWORD lpdwLen,
  [in]      DWORD   Reserved
);

Parameters

[in] hUrlCacheStream

Handle that was returned by the RetrieveUrlCacheEntryStream function.

[in] dwLocation

Offset to be read from.

[in, out] lpBuffer

Pointer to a buffer that receives the data.

[in, out] lpdwLen

Pointer to a variable that specifies the size of the lpBuffer buffer, in bytes. When the function returns, the variable contains the number of bytes copied to the buffer, or the required size of the buffer, in bytes.

[in] Reserved

This parameter is reserved and must be 0.

Return value

Returns TRUE if successful, or FALSE otherwise. To get extended error information, call GetLastError.

Remarks

If the buffer size is not sufficient, GetLastError returns ERROR_INSUFFICIENT_BUFFER and sets lpdwLen to the size necessary to contain all the information.

Like all other aspects of the WinINet API, this function cannot be safely called from within DllMain or the constructors and destructors of global objects.

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).
 

Requirements

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

Caching

WinINet Functions