InternetLockRequestFile function (wininet.h)
Places a lock on the file that is being used.
BOOL InternetLockRequestFile(
[in] HINTERNET hInternet,
[out] HANDLE *lphLockRequestInfo
);
[in] hInternet
Handle returned by the FtpOpenFile, GopherOpenFile, HttpOpenRequest, or InternetOpenUrl function.
[out] lphLockRequestInfo
Pointer to a handle that receives the lock request handle.
Returns TRUE if successful, or FALSE otherwise. To get a specific error message, call GetLastError.
If the HINTERNET handle passed to hInternet was created using INTERNET_FLAG_NO_CACHE_WRITE or INTERNET_FLAG_DONT_CACHE, the function creates a temporary file with the extension .tmp, unless it is an HTTPS resource. If the handle was created using INTERNET_FLAG_NO_CACHE_WRITE or INTERNET_FLAG_DONT_CACHE and it is accessing an HTTPS resource, InternetLockRequestFile fails.
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.
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 |