SECIContextMenuImpl::AddCommand

HRESULTSECIContextMenuImpl::AddCommand(LPCTSTRstrName, LPCTSTRstrHelp, UINTnCommandID)

This method adds a context menu command to the list of commands that will be added to the context menu. Commands can either be added from resources or literal strings. As an alternative, you can use the Command Map Macros, which call this method internally.

Defined in: SECIContextMenuImpl.h

Return Value

HRESULT Return S_OK if all the command are successfully loaded, otherwise return E_FAIL.

Parameters

strName

The string to be used as context menu text.

strHelp

The string to be used as help string for this context menu item

nCommandID

The Command ID to identify this context menu item. You can check the nID argument of CommandHandler method to look for this command ID.