这个问题还没搞定就放弃了, 请下载:
http://support.microsoft.com/download/support/mslfiles/Mimetype.exe
这是微软的InPlacePlayer的一个例子(C++), 示范了如何做一个MIME(Multimedia
Internet Mail Extension)ActiveX播放远程媒体文件.
下面是MSDN的一段话:
Downloading the File
Internet Explorer does not download the file before sending the URL
to the player. The player is responsible for retrieving the file and
playing it. There are a number of ways to handle this depending on
what the player needs to do. One way is illustrated in the sample
with the URLDownloadToCacheFile function. This function downloads the
file only if necessary and returns the name of the local cached copy
of the file. It should be noted that URLDownloadToCacheFile is a
blocking function. Even though the data is downloaded asynchronously
the function does not return until all the data is downloaded.
If complete asynchronous downloading is desired, one of the other UOS functions, such as URLOpenStream, or perhaps general URL monikers would be more appropriate. The following code is taken from CMimetypeCtrl:
oPropExchange (in Mtpctl.cpp) and fills up the string m_cstrCacheFileName with the complete path of the local file:
if ( FAILED(URLDownloadToCacheFile(
GetControllingUnknown(), // control's IUnknown
m_cstrFileName, // URL to download
m_cstrCacheFileName.GetBuffer(MAX_PATH),// buffer to fill with name
MAX_PATH, // buffer length
0, // reserved
NULL )) ) // no status information
{
AfxMessageBox("Cannot download file");
m_cstrCacheFileName = "Not Found";
return;
}