IFileViewer::ShowInitialize

[Now Supported on Windows NT]

Allows a file viewer to determine whether it can display a file and, if it can, to perform initialization operations before showing the file.

The shell calls this member function before the IFileViewer::Show member function. The shell specifies the name of the file to display by calling the file viewer's IPersistFile::Load member function.

IFileViewer::ShowInitialize must perform all operations that are prone to failure so that if it succeeds, IFileViewer::Show will not fail.

HRESULT ShowInitialize(

IFileViewer FAR *pFileViewer,  
LPFILEVIEWERSITE lpfsi  
);  

Parameters

pFileViewer

Address of the IFileViewer interface. In C++, this parameter is implicit.

lpfsi

Address of a IFileViewerSite interface. A file viewer uses this interface to retrieve the handle of the current pinned window or to specify a new pinned window.

Return Values

Returns the NOERROR value if successful or an OLE-defined error value otherwise.

See Also

IFileViewer