The way a ribbon button is displayed indicates its availability in the program.
A ribbon button can be displayed as:
You can gray out a ribbon button by using a DIESEL string expression.
When grayed out, the macro and submenus associated with the ribbon button are made inaccessible.
The following DIESEL string expression, placed in the Macros property of the Properties pane, disables the macro while another command is active.
$(if,$(getvar,cmdactive),~)MOVE^C^C_move
The AutoLISP menucmd function can also be used to disable and enable items from a macro or AutoLISP application.
You can mark a ribbon button by using a DIESEL string expression.
When a ribbon button is marked, a border is displayed around the image.
DIESEL string expressions can be used to conditionally mark a ribbon button each time it is displayed. The following DIESEL string examples, when added to the Macros property of the Properties pane, highlight the ribbon button when the related system variable is enabled.
$(if,$(getvar,orthomode),!.)Ortho^O $(if,$(getvar,snapmode),!.)Snap^B $(if,$(getvar,gridmode),!.)Grid^G
You can mark and disable a ribbon button at the same time using either of the following formats:
~!.labeltext !.~labeltext