FindCommand Method
See Also 
SourceCode.Framework.Design Namespace > MenuCommandServiceBase Class : FindCommand Method



commandID
The System.ComponentModel.Design.CommandID to search for.

Glossary Item Box

Searches for the specified command ID and returns the menu command associated with it.

Syntax

Visual Basic (Declaration) 
Public Overridable Function FindCommand( _
   ByVal commandID As CommandID _
) As MenuCommand
Visual Basic (Usage)Copy Code
Dim instance As MenuCommandServiceBase
Dim commandID As CommandID
Dim value As MenuCommand
 
value = instance.FindCommand(commandID)
C# 
public virtual MenuCommand FindCommand( 
   CommandID commandID
)
C++/CLI 
public:
virtual MenuCommand^ FindCommand( 
   CommandID^ commandID
) 

Parameters

commandID
The System.ComponentModel.Design.CommandID to search for.

Return Value

The System.ComponentModel.Design.MenuCommand associated with the command ID, or null if no command is found.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also