SetMenuBarFrom Planimate Knowledge BaseRoutine Operation that interprets columns in table as depth/name/index/unselectable/selected(tick) and builds a custom menu bar. SetMenuBar enables a complete modeller customsied menubar, with hierarchic menus, to be built in one step. It superceeds the "ClearCustomMenubar" and "AddListToMenu" routine operations. The operation takes a 5 column table as a parameter (the table can have more than 5 columns but only the first 5 are used). The name of the columns are not important but the positions must be ordered as follows. The columns are:
You can use a label of '-' as a separator between menu items. When a menu bar selection is made the system broadcast "_Menu Command" is sent and the item attribute "_command" will contain the index (from the index column) of the selected menu item. Menu items flagged as unavailable will be shown in Grey and cannot be selected. Useful when creating end user applications with Planimate. |
