Chapter 19. Context Menus
Detail windows and task panes discussed above are shown in the SelectionChange event.
We can add such queries and much more to the context menu.
Let's add the following configuration to the EventHandlers table (two lines at the bottom):
Then let's switch to the payments workbook, select the Payments worksheet, click Reload, Reload Data and Configuration, and right click on a row:
When we click on the Company Payments item, the add-in shows the task pane like this:
As we learned above, the SelectionChange and ContextMenu handlers are nearly the same.
They get parameters from the columns of the active row. They differ by the EVENT_NAME configuration.
However, the ContextMenu handlers support additional configuration parameters like MENU_ORDER and EDIT_PARAMETERS:
and allow using much more handler types:
You can configure executing stored procedures, SQL codes, macros, CMD commands, opening URLs.
Use the MenuSeparator type to separate menu items.