i can destroy or close a Menu open from MenuButton control with a cmd like this
code:
i tyed
var hand = PlusWnd1.GetControlHandle('MnuCED')
var wh = PlusWnd1.handle
var i = Interop.Call("User32","GetMenu",wh)
var ii = Interop.Call("User32","IsMenu",hand)
var iii = Interop.Call("User32","DestroyMenu",hand)
Debug.Trace('Menu test: ' +wh+' ' +hand+' ' +i+' ' +ii+ ' '+iii)
Menu test: 7406936 0 0 0 0
i see i canT get the handle for the menu with getcontrolhandle
that not work, but a cmd exist for close the menu?
code:
<Control xsi:type="MenuButtonControl" Id="BtnAdd_Edit">
<Position Top="92" Left="9" Width="70" Height="14"/>
<Attributes>
<AlwaysDisplayBorder>true</AlwaysDisplayBorder>
</Attributes>
<TextColor><GlobalColor>black</GlobalColor></TextColor>
<Menu Id="MnuCED" VPos="Bottom" HPos="CenterLeft">