We recommend using Visual Studio 2017
This documentation is archived and is not being maintained.


Implements the user interface for the typename Object command.

void AFXAPI AfxOleSetEditMenu( 
   COleClientItem* pClient, 
   CMenu* pMenu, 
   UINT iMenuItem, 
   UINT nIDVerbMin, 
   UINT nIDVerbMax = 0, 
   UINT nIDConvert = 0  


A pointer to the client OLE item.


A pointer to the menu object to be updated.


The index of the menu item to be updated.


The command ID that corresponds to the primary verb.


The command ID that corresponds to the last verb.


ID for the Convert menu item.

If the server recognizes only a primary verb, the menu item becomes "verb typename Object" and the nIDVerbMin command is sent when the user chooses the command. If the server recognizes several verbs, then the menu item becomes "typename Object" and a submenu listing all the verbs appears when the user chooses the command. When the user chooses a verb from the submenu, nIDVerbMin is sent if the first verb is chosen, nIDVerbMin + 1 is sent if the second verb is chosen, and so forth. The default COleDocument implementation automatically handles this feature.

You must have the following statement in your client's application resource script (.RC) file:

#include <afxolecl.rc>

Header: afxole.h