BINDF_GETNEWESTVERSION Does Not Work in URLDownloadToCacheFile Function

ID: Q196466


The information in this article applies to:


SYMPTOMS

When you develop a Web-based program using the URLDownloadToCacheFile function provided by Urlmon.dll, you may notice that the BINDF_GETNEWESTVERSION flag, passed in as the dwReserved parameter, does not function properly.

As a result of this improper functioning, the Web-based program always gets the required information from the local cache rather than going to the Web server for the information.


RESOLUTION

To resolve this problem, obtain and install Internet Explorer 4.01 Service Pack 2. You can obtain Internet Explorer 4.01 Service Pack 2 from the following Microsoft Web site:

http://www.microsoft.com/ie/download


STATUS

Microsoft has confirmed this to be a problem in Internet Explorer version 4.01 SP1 for Windows 95 and Windows NT 4.0, and in Windows 98.


MORE INFORMATION

The Microsoft Developer Network (MSDN) defines the BINDF_GETNEWESTVERSION operation as follows:

The Bind operation should retrieve the newest version of the data/object possible. For URL monikers, this flag maps to the Win32 Internet API flag INTERNET_FLAG_RELOAD, which forces a download of the requested resource.

MSDN also defines the Urlmon.dll-provided URLDownloadToCacheFile function with the following function prototype:


   HRESULT URLDownloadToCacheFile( 
LPUNKNOWN lpUnkcaller, LPCSTR szURL, LPTSTR szFileName, DWORD dwBufLength, DWORD dwReserved, IBindStatusCallback *pBSC );


Note that the function documentation states that the parameter named dwReserved is reserved and must be set to zero. However, BINDF_GETNEWESTVERSION is a flag value that can be passed into this function as a dwReserved parameter to provided the appropriate functionality.

Additional query words:


Keywords          : kbprg msiew95 msient win98 
Version           : WINDOWS:4.01 Service Pack 1,4.01sp1
Platform          : WINDOWS 
Issue type        : kbprb 

Last Reviewed: April 2, 1999