SOLIDWORKS PDM Professional API Help Send Feedback
OnMenuItem Method (IEdmMenu5)
See Also 
EPDM.Interop.epdm Namespace > IEdmMenu5 Interface : OnMenuItem Method (IEdmMenu5)


lItemID
ID of the selected menu item
lParentWnd
Parent window handle (HWND)
lCurrentFolderID
ID of the currently active folder
poSelFiles
List of selected files
poSelFolders
List of selected folders
Obsolete. Superseded by IEdmMenu7::OnMenuItem2.

Syntax

Visual Basic 
Function OnMenuItem( _
   ByVal lItemID As System.Integer, _
   ByVal lParentWnd As System.Integer, _
   ByVal lCurrentFolderID As System.Integer, _
   ByVal poSelFiles As EdmSelectionList5, _
   ByVal poSelFolders As EdmSelectionList5 _
) As System.Integer
C# 
System.int OnMenuItem( 
   System.int lItemID,
   System.int lParentWnd,
   System.int lCurrentFolderID,
   EdmSelectionList5 poSelFiles,
   EdmSelectionList5 poSelFolders
)
C++/CLI 
System.int OnMenuItem( 
&   System.int lItemID,
&   System.int lParentWnd,
&   System.int lCurrentFolderID,
&   EdmSelectionList5^ poSelFiles,
&   EdmSelectionList5^ poSelFolders
) 

Parameters

lItemID
ID of the selected menu item
lParentWnd
Parent window handle (HWND)
lCurrentFolderID
ID of the currently active folder
poSelFiles
List of selected files
poSelFolders
List of selected folders

Return Value

User-interface elements that should be refreshed as defined in EdmRefreshFlag

Remarks

You should call this method when a user selects a menu item belonging to this menu.

Return codes:

  • S_OK: The method successfully executed.
  • S_FALSE:  Menu item does not belong to this menu.
  • S_EDM_MENU_ITEM_NOT_APPLICABLE: The current selection of files and folders do not satisfy the constraints set by the command author. See EdmMenuFlags sent to IEdmCmdMgr5::AddCmd.
 

See Also

Availability

Version 5.2 of SOLIDWORKS PDM Professional