Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

IContextMenuSite interface

[The only method, DoContextMenuPopup, is no longer available for use as of Windows Server 2003.]

Implemented by the default folder view created using SHCreateShellFolderView. An implementation of IContextMenuSite supports IContextMenu::QueryContextMenu, IContextMenu::InvokeCommand, and TrackPopupMenu and any message forwarding necessary for that function. IContextMenuSite typically updates the status bar as well.

Members

The IContextMenuSite interface inherits from the IUnknown interface. IContextMenuSite also has these types of members:

Methods

The IContextMenuSite interface has these methods.

MethodDescription
DoContextMenuPopup

Creates and displays a shortcut menu, tracks the selection of items on that menu, and invokes a chosen command.

 

Remarks

The IID for this interface is IID_IContextMenuSite.

To acquire a context menu site pointer code that exists in the site chain of the folder view, use QueryService using SID_SFolderView to get to the folder view.


CComPtr<IContextMenuSite> spcms;
hr = IUnknown_QueryService(_punkSite, SID_SFolderView, IID_PPV_ARGS(&spcms));

if (SUCCEEDED(hr))
{
    ...
}

Requirements

Minimum supported client

Windows 2000 Professional [desktop apps only]

Minimum supported server

Windows 2000 Server [desktop apps only]

Header

Shobjidl.h

IDL

Shobjidl.idl

DLL

Shell32.dll (version 5.0 or later)

 

 

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.