This content demonstrates how to retrieve the user assigned to the workflow for purchase orders in Dynamics 365 for Finance and Operations using X++ code. The given code extends the PurchTable table and includes a method to get the workflow assignee based on the pending status of the workflow work item.
D365: How to get last workflow approver in X++
This X++ code demonstrates how to retrieve the last workflow approver in Dynamics 365 for Finance and Operations using the getLastWorkflowApprover method. It joins tables to select the appropriate workflow tracking information and user details, returning the user ID of the last workflow approver.
D365FO: Submit pending vendor invoice to workflow in X++
Purpose: In this post we're going to learn how can we submit a pending vendor invoice to approval workflow in X++. Application: Dynamics 365 for Finance and Operations Business requirement: Submit a pending vendor invoice to approval workflow in X++. Solution: We can use the code below to submit a pending vendor invoice to approval... Continue Reading →
D365FO: Get last workflow approver for purchase orders in X++
Purpose: In this post we're going to see how can we get last workflow approver for purchase orders in X++. Application: Dynamics 365 for Finance and Operations. Business requirement: Get the last purchase order approver in X++. Solution: Please use the code below to get the last purchase order approver. Tip: Take a note that... Continue Reading →