InternetQueryDataAvailableInternetQueryDataAvailable*
*



Contents  *



Index  *Topic Contents
*Previous Topic: InternetOpen
*Next Topic: InternetQueryOption

InternetQueryDataAvailable

BOOL InternetQueryDataAvailable( 
    IN HINTERNET hFile,
    OUT LPDWORD lpdwNumberOfBytesAvailable,
    IN DWORD dwFlags,
    IN DWORD dwContext
);

Queries the amount of data available.

hFile
Valid Internet file handle, as returned by InternetOpenUrl, FtpOpenFile, GopherOpenFile, or HttpOpenRequest.
lpdwNumberOfBytesAvailable
Optional. Address of a variable that receives the number of available bytes.
dwFlags
Reserved; must be zero.
dwContext
Reserved; must be zero.

This function returns the number of bytes of data that are available to be read immediately by a subsequent call to InternetReadFile. If there is currently no data available and the end of the file has not been reached, the request waits until data becomes available. The amount of data remaining will not be recalculated until all available data indicated by the call to InternetQueryDataAvailable is read.

For HINTERNET handles created by HttpOpenRequest and sent by HttpSendRequestEx, a call to HttpEndRequest must be made on the handle before InternetQueryDataAvailable can be used.


Up Top of Page
© 1997 Microsoft Corporation. All rights reserved. Terms of Use.