Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics CRM (Archived)

Workflows Owner vs Record Auditing

Posted on by 1,545

I am the owner of most workflows in our CRM. Most of them fire on specific actions or field changes, etc.

When a user changes a field that triggers a workflow, I come up as the user that updated the record in the Audit History.

I would like to see the user who actually fired the workflow to show un the Audit History.

Is this possible?

We are using CRM 365 (8.2) on-premise.

Most workflows are running in background, and scope is set to "Organization".

Thanks..

*This post is locked for comments

  • Suggested answer
    Kokulan Profile Picture
    Kokulan 18,048 on at
    RE: Workflows Owner vs Record Auditing

    I know it's a lot of work but what if you have a lookup field on the entity, let's call it Update as or something along the line. In the workflow, set the value for this field to be the owner or whoever you want. And create a plugin on Pre-Validation stage and set the Modified By to the value from this new field. Since CRM won't change the value after validation, it should work.

  • yleclerc Profile Picture
    yleclerc 1,545 on at
    RE: Workflows Owner vs Record Auditing

    Not really. We have so many workflows that affect many entities at that we have to dig in the audit a lot. Some workflows then fire child workflows so it's difficult to keep track of who initiated the original one.

  • Caye Solutions Profile Picture
    Caye Solutions 30 on at
    RE: Workflows Owner vs Record Auditing

    Yvan, did you figure this out? I am looking for a similar solution.

  • yleclerc Profile Picture
    yleclerc 1,545 on at
    RE: Workflows Owner vs Record Auditing

    Yes, most of them are Background. I would not mind switching them to Real-Time, but they don't work well when fired from our Customer Portal.

    Our workflows fire on field or status change or even on-demand.

    But if a workflow is triggered by a user, and that workflow updates other fields, I always show as the user who updated those other fields in the audit history. But I would like the user (not me) who caused the workflow to fire to show in the audit history...

  • Suggested answer
    a33ik Profile Picture
    a33ik 84,323 Most Valuable Professional on at
    RE: Workflows Owner vs Record Auditing

    Aric, I can be wrong but you have that choice only for Real-Time workflows. Yvan mentioned that most of workflows are "Background" so there is no that option. Correct me if I'm wrong.

  • Aric Levin Profile Picture
    Aric Levin 30,188 on at
    RE: Workflows Owner vs Record Auditing

    Under what context is the workflow running? Although you are the owner of the Workflow, the workflow can run in the user's context or the owner's context.

  • Suggested answer
    a33ik Profile Picture
    a33ik 84,323 Most Valuable Professional on at
    RE: Workflows Owner vs Record Auditing

    Hello,

    This is possible. To do that you will have to do following:

    1. Add Lookup to user to entity you want to track changes of and turn audit for this field on. It will store reference to use who initiated workflow.

    2. Use custom workflow step "Get Initiating User" from this toolkit - github.com/.../Dynamics-365-Workflow-Tools

    3. Inside your workflow populate lookup created on the step 1 with the result you retrieve from step 2.

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,280 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,214 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans