Blog

Microsoft Dynamics AX Blog

0

Workflow in Dynamics AX 2009 is interesting technical part of this lovely product. When you try to develop/create a new workflow in Dynamics AX you might get confused of the so many menu items and classes that you create, and sometime you don’t even know what these classes’ handlers and menu items are used for. That’s why when I first learned how to create workflow in Dynamics AX one year ago; I created a pretty easy-to-use wizard that creates for you a workflow with all the necessary objects like Workflow Template, approval, category, classes and menu items. Furthermore, this wizard enables the workflow on the selected form and its main table.

One of the important classes that you need to set at the approval process is the participant provider. The goal of this property is for the workflow to decide who will be the participant user for this step of workflow. To do that, you have to extend WorkflowParticipantProvider class and overwrite the methods: getParticipantTokens that fills the list of options in the Role Based section of and resolve that will decide the exact user based on some X++ and the selected option in Role Based list.

Dynamics AX 2009 Workflow - Assignment - Role based

Dynamics AX 2009 Workflow - Assignment - Role based

By default, Dynamics AX 2009 comes with three participants:

  1. WorkflowUserGroupParticipantProvider:
  • List all configured User Groups in the system and assigns the workflow step to all users in the selected group
  1. ProjWorkflowParticipantProvider:
  • This is for Purchase Requisition workflow. List some tokens like Project Manager, Project Controller, Project Sales and others and assigns the workflow step to the assigned person of the Purchase Requisition project.
  1. TrvWorkflowProjParticipantProvider:
  • This is for Expense Management workflow. List tokens like Project Manager, Project Controller, and Project Sales and assigns the workflow step to the assigned person of the expense project.

 

Workflow Approval Properties

Workflow Approval Properties

So simply, when you need to specify participants based in your criteria, you need to do exactly the same of those classes, by overwriting getParticipantTokens and resolve.

Dynamics AX 2012 Event

Recent Posts

Tags

Archives

Random Testimonial

  • ~ Muheet Shariff, Dynamics AX Consultant

    muheet"I have found Amer a pleasant, generous person who is never afraid to take on a challenging task.Amer is an independent, self directed person who is able to communicate effectively and meet even the most demanding challenges. I am positive he will make outstanding contributions to Microsoft technologies. It was a great experience working with Amer during our implementation of Dynamics AX at  Al-Fahad and Al-Othaim companies. His support to Microsoft Dynamics AX is outstanding and very professional. Technically he sounds very strong. It was a great pleasure to be associated along with Amer performing some challenging tasks. I wish him to reach the desired success with his professionalism."

  • Read more testimonials »