IVsSmartTagData.GetContextMenuInfo(Guid, Int32, IOleCommandTarget) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets information about the context menu.
public:
int GetContextMenuInfo([Runtime::InteropServices::Out] Guid % guidID, [Runtime::InteropServices::Out] int % nMenuID, [Runtime::InteropServices::Out] Microsoft::VisualStudio::OLE::Interop::IOleCommandTarget ^ % pCmdTarget);
public int GetContextMenuInfo (out Guid guidID, out int nMenuID, out Microsoft.VisualStudio.OLE.Interop.IOleCommandTarget pCmdTarget);
abstract member GetContextMenuInfo : Guid * int * IOleCommandTarget -> int
Public Function GetContextMenuInfo (ByRef guidID As Guid, ByRef nMenuID As Integer, ByRef pCmdTarget As IOleCommandTarget) As Integer
Parameters
- guidID
- Guid
[out] The GUID of the context menu.
- nMenuID
- Int32
[out] The menu ID of the context menu.
- pCmdTarget
- IOleCommandTarget
[out] The IOleCommandTarget of the context menu.
Returns
If the method succeeds, it returns S_OK. If it fails, it returns an error code.
Remarks
COM Signature
From textmgr2.idl:
HRESULT IVsSmartTagData::GetContextMenuInfo(
[out] GUID *guidID,
[out]long *nMenuID,
[out]IOleCommandTarget **pCmdTarget
);
GetContextMenuInfo
returns S_FALSE if OnInvocation
should be called for non-context menu UIs.