Ok. Thanks
COMUNIDAD. AUT. REG MURCIA
Original Message:
Sent: 04-02-2024 02:01
From: Peter Møller
Subject: Disable menu ribbon
Hi Mayca
If you have used the RibbonLib from the MapBasic Common Libraries, you may also be aware of the many procedures in this module for handling controls.
The one you want to look at is RBNControlEnableThs
.
It holds numerous calls to the various dedicated methods for the specific control type.
For the Button
control type, you want to use this:
Call SetRbnBtnCtrlEnabled(rbnControl, bEnabled)
The bEnabled
variable can be True
or False
depending on whether you want to Enable
to Disable
to control.
------------------------------
Peter Horsbøll Møller
Principal Presales Consultant | Distinguished Engineer
Precisely | Trust in Data
Original Message:
Sent: 03-25-2024 09:29
From: Mayca González Pérez
Subject: Disable menu ribbon
Hello. I have a menu with its options and I want the option to be disabled. And then with a code that can activate it. That is, I want an analogue of ALTER MENU ID 150 DISABLED
Dim DropObjeto as ThisDropObjeto = MICtrlCollAddStrStrInt(EielControlCol, "DropObjeto", "Objetos ", ControlType_DropDownButton)Dim DropControlObjeto as ThisDropControlObjeto = GetRbnDropDownCtrlCtrls(DropObjeto)Dim btnMarca, btnMarca2, btnCombinar, btnDividir, btnDividir2, btnBorrar1, btnBorrar2, btnCRegiones, btnCPoli, sepObjeto1, sepObjeto2, sepObjeto3 as ThisbtnMarca = MICtrlCollAddStrStrInt(DropControlObjeto, "OpenBtn", "Establecer marca", ControlType_Button)Call SetRbnBtnCtrlSmallIcon(btnMarca, New_Uri("pack://application:,,,/MapInfo.StyleResources;component/Images/Mapping/openTable_32x32.png", 0))Call SetRbnBtnCtrlCallingHandler (btnMarca, "SelectTarget")
Thanks
------------------------------
Mayca González Pérez
COMUNIDAD. AUT. REG MURCIA
------------------------------