Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics 365 | Integration, Dataverse...
Suggested answer

allow to execute Workflows only for Users who created an activity

(0) ShareShare
ReportReport
Posted on by 5

Hi there,

I created an re-open workflow for activity entities (eg. Phonecall). This Workflow should only be executed by the User who created it. I couldn´t find a solution for this. Neither in the Workflow itself nor as a business rule. Even the Ribbon Workbench only allow to have privileges on rules not on a current user base.

So what I need is something like that: if current user equals field value in created by field, then show Button re-open Workflow or let him execute the workflow without any error message. If the current user does not equal the created by field value, than hide the Button or don´t let him execute the Workflow and show error message.

I work on a 8.2 Version and have no clue about scripting

Any suggestions?

  • Suggested answer
    Torrado Profile Picture
    Torrado 1,270 on at
    RE: allow to execute Workflows only for Users who created an activity

    Hello,

    You need to configure Enable Rule for that button, to show only when the user is the creator of the activity record.

    Please refer to this post by the Ribbon Workbench author (it has video as well) to understand how the Enable Rules are configured: ribbonworkbench.uservoice.com/.../121427-enable-disable-a-ribbon-button-dynamically-based-o

    You might need to modify and combine the script to get the "Current User Id" compared to the "Created By Id" value.

    Please check this article about how to get the current user for your D365 version: crmorion.blogspot.com/.../how-to-get-current-user-id-in-crm-2013.html

    Hope this helps you,

    Please mark the answer as verified if helpful. That will help others in future.

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 Verified Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

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

#2
Martin Dráb Profile Picture

Martin Dráb 230,445 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Product updates

Dynamics 365 release plans