Initializes a handler with a stream.
HRESULT Initialize( IStream *pstream, DWORD grfMode );
A pointer to an IStream interface that represents the stream source.
One of the following STGM values that indicates the access mode for pstream.
The stream indicated by pstream is read-only.
The stream indicated by pstream is read/write accessible.
If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.
This method is preferred to Initialize due to its ability to use streams that are not accessible through a Win32 path, such as the contents of a compressed file with a .zip file name extension.
The stream pointed to by pstream must remain open for the lifetime of the handler or until IPropertyStore::Commit is called.
When first opened, the source stream reference points to the beginning of the stream. The handler can seek and read from the stream at any time. A handler can be implemented to read all properties from the stream during Initialize or it can wait until the calling process attempts to enumerate or read properties before fetching them from the stream.
A handler instance should be initialized only once in its lifetime. Attempts by the caller to reinitialize the handler should result in the error
|Minimum supported client||Windows Vista [desktop apps only]|
|Minimum supported server||Windows Server 2008 [desktop apps only]|