web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

Running Automated task in Workflow

(0) ShareShare
ReportReport
Posted on by 2,013

Hi all,

I'm creating an Automated task in my workflow, put after 1 of my approval steps. Question is, is Automated task only run if the outcome of my approval is Yes (approved). How if I also want to run it when it is Rejected as well ?

The task is only to send email. Why I created automated task is because I need the program to find first my custom field consist of an email address. So it need to run provided the Workflow Approved or Rejected.

Currently I noticed and presumed why my Automated task didn't run is because when my workflow is rejected, the workflow status will still "Pending". Is that the cause ?

Kindly advice.

Thanks in advance,

Anton

*This post is locked for comments

I have the same question (0)
  • Jonathan  Halland Profile Picture
    11,310 on at

    Hi Anton.

    Why don't you use the standard notifcations in workflow to notify them of rejections?

  • Anton Tjiptadi Profile Picture
    2,013 on at

    Hi,

    As I know, in standard notification we must select a fixed user. In my case the user is dynamic depend on what mentioned in the document, for example in my Sales Order.

    Ok, the actual plan is I have Sales limit approval. when it is approved or reject, I need to send email, not only to workflow originator or to someone which is fixed to one person, but I want to notify the Sales Responsible stated in my Sales Order. It can be anyone in my Sales person list so does the email based on what setup in their Employee table.

    Any advise is appreciated. Thanks.

  • Verified answer
    Jonathan  Halland Profile Picture
    11,310 on at

    Hi Anton. We found a very neat way to do this in AX2012 is by creating custom Participant providers to resolve specific, criteria based, groups of people.

  • Anton Tjiptadi Profile Picture
    2,013 on at

    Hi Jonathan,

    I'm not familiar for using participant but ain't participant is some kind of user group ?

    Can you give me some example or further explanation ?

    As mentioned, my target is quite simple, to email the sales responsible specified in my sales order header.

    Thanks in advance,

    Anton

  • Verified answer
    Jonathan  Halland Profile Picture
    11,310 on at

    Hi Anton.

    A participant provider is simply a code class that you can create to return any selection of users that you would like. This could be a hard-coded set, it could be based off some user groups in AX, it could be from a field on your document etc...

    I wrote this blog post on Tuesday for somebody with a similar type of requirement. www.exploreax.com/.../workflow-user-selectable-approver

    For your requirement, instead of selecting participant on the "assingment" functionality, you would select it on the notification you are referring to.

  • Anton Tjiptadi Profile Picture
    2,013 on at

    Hi Jonathan,

    Sorry for looongg time no reply... but just tried your tips and it works. Thank you so much for the help, it is very helping.

    Thanks again.

  • Jonathan  Halland Profile Picture
    11,310 on at

    I'm glad it worked!

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Meet the Microsoft Dynamics 365 Contact Center Champions

We are thrilled to have these Champions in our Community!

Congratulations to the March Top 10 Community Leaders

These are the community rock stars!

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
CP04-islander Profile Picture

CP04-islander 16

#2
GiacomoRovai Profile Picture

GiacomoRovai 4

#3
Douglas Noel Profile Picture

Douglas Noel 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans