WinDataDrivenAdapter.FindMenuItem Method

Definition

Finds the menu item associated with a control.

protected:
 bool FindMenuItem(System::String ^ controlName, bool throwExceptionIfNotFound, [Runtime::InteropServices::Out] IntPtr % hMenu, [Runtime::InteropServices::Out] int % subMenuIndex, [Runtime::InteropServices::Out] int % hMenuItemId);
protected bool FindMenuItem (string controlName, bool throwExceptionIfNotFound, out IntPtr hMenu, out int subMenuIndex, out int hMenuItemId);
member this.FindMenuItem : string * bool * nativeint * int * int -> bool
Protected Function FindMenuItem (controlName As String, throwExceptionIfNotFound As Boolean, ByRef hMenu As IntPtr, ByRef subMenuIndex As Integer, ByRef hMenuItemId As Integer) As Boolean

Parameters

controlName
String

Specifies the name of the control.

throwExceptionIfNotFound
Boolean

Contains a Boolean value that, when true, throws DataDrivenAdapterException if the control isn’t found.

hMenu
IntPtr

nativeint

Specifies the handler for the menu item.

subMenuIndex
Int32

Specifies the submenu index.

hMenuItemId
Int32

Specifies the Id of the menu item control.

Returns

true if it finds the control; otherwise, false.

Applies to