다음을 통해 공유


ShowUI method

Enables the host to replace MSHTML menus and toolbars.

Syntax

HRESULT retVal = object.ShowUI(dwID, pActiveObject, pCommandTarget, pFrame, pDoc);

Parameters

Remarks

If the host uses any of the interfaces handed to it as part of this function, the host should call the interface's AddRef method to save the interface for later use. If the host calls the interface's AddRef method, the host must also call the interface's Release method when the interface is no longer required.

To avoid a memory leak, forward calls to IDocHostUIHandler::ShowUI to the default UI handler.

A host can disable modeless UI on MSHTML by calling IOleCommandTarget::Exec with IDM_DISABLEMODELESS and IDM_ENABLEMODELESS.