In a large application, it is very likely that a substantial amount of code is used to dynamically set menu properties or is executed in a function, or during specific events.
The ribbon items will be automatically synchronized with the properties, functions and events of the corresponding menu items. This ensures that the original application runs smoothly without requiring any modifications to the existing code.
For example, the following code will still take effect after the menu is displayed in RibbonView.
Example 1: Code that controls whether menu items are hidden.
lm_current.m_report.visible = ab_flag lm_current.m_report.m_categorystatistic.visible = ab_flag lm_current.m_report.m_categorystatistic.toolbaritemvisible = ab_flag
Example 2: Code that enables a menu item.
lm_current.m_action.m_add.Enabled = lb_flag