Hi Team,
I am currently working with workflows in Dynamics 365 Finance & Operations and trying to understand how the workflow action menu is dynamically generated at runtime.
For a custom workflow, I understand that the Workflow button is enabled dynamically based on the workflow status. However, when I click the Workflow button, it displays different submenu actions depending on the current workflow state.
For example:
- Before submission → Submit
- After submission → Recall, View History, etc.
- Depending on the workflow status, the available actions change dynamically.
I would like to understand where these workflow submenu items are being generated and what is responsible for determining which actions are displayed at runtime.
I have tried debugging the workflow execution and menu-related code at several points, but I have not been able to identify the main method/class responsible for dynamically building these submenu items.
Could anyone please point me in the right direction regarding:
- Which class/method is responsible for generating the workflow action submenus?
- Is there a framework class or method that I should focus on while debugging this behavior?
- If possible, could you provide an example or debugging approach to trace the Submit → Recall → View History menu generation?
Any guidance on where to start debugging this framework functionality would be greatly appreciated.
Thanks in advance!

Report
All responses (
Answers (