RibbonInfo() function - MapBasic - 2023

MapInfo MapBasic Reference

Product type
Software
Portfolio
Locate
Product family
MapInfo
Product
MapInfo > MapBasic
Version
2023
Language
English
Product name
MapBasic
Title
MapInfo MapBasic Reference
First publish date
1985
Last updated
2023-09-12
Published on
2023-09-12T16:32:32.686312

Purpose

Returns a property value of a ribbon control. A ribbon control can be the ribbon itself, a ribbon tab, a ribbon group, a contextual tab group, or an individual control or sub control on the ribbon. You can call this function from the MapBasic window in MapInfo Pro.

Syntax

RibbonInfo( control_name, property_name [, ribbon_windowid ] ) 

control_name is the unique name specified when creating the control, or the name of a built-in control. See RibbonControls.def for a list of built-in control names. It is a string expression, and the name property is case sensitive. It must start with a letter or underscore and can contain numbers, letters and underscores. If the control is added by another MBX or using .NET, python or mapbasic function calls, the name will not be found and will cause an error. Only built-in controls and controls added by an MBX via MapBasic statements can be found this way.

property_name is the name of a property for the specified control. The properties vary based on the type of the control being queried.

ribbon_windowid is an optional parameter that specifies the numeric id of the ribbon window. If this parameter is not passed, the main ribbon window is taken.

Return Value

Property

Note: Refer Ribbon Token and Property Mappings to see which ribbon token sets the corresponding ribbon property. You can access these properties using the RibbonInfo() and the RibbonItemInfo() functions.

Example

RibbonInfo(PRO_RIBBON, PROPERTY_CAPTION)