OnMenuAction¶
Called when the user clicks a plugin menu item.
When is this called?
Use Host API callbacks during execution to interact with the host application.
C# Override¶
public override void OnMenuAction(OnMenuActionRequest request)
{
if (request.MenuItemId != "my-search")
return;
Host.ShowMessage("Hello from MyPlugin");
}
Request¶
| Field | Type | Required | Description |
|---|---|---|---|
menuItemId |
string |
โ | ID of the clicked menu item. |
parentWindowHandle |
integer |
โ | HWND for modal dialog ownership. |
context |
PluginContext |
โ | Current host application state. |
Response¶
This method returns no data on success.
JSON¶
The SDK serializes these JSON bodies for you.