Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Microsoft Dynamics 365 | Integration, Dataverse...
Answered

Close a task (complete) as another is created

(0) ShareShare
ReportReport
Posted on by 30

Hi! Im working on an app that should allow the users to have only one open activity record per opportunity. I want to know if there is a way to create a workflow or other process that automatically completes any existing open activity records (appointment, phone call or email) attached to an opportunity, at the moment that another activity as such is created.

This would ensure that only one activity can be open at any point in time for every opportunity.

Thanks,

Pedro

  • Verified answer
    Community Member Profile Picture
    on at
    RE: Close a task (complete) as another is created

    Hi Pedro,

    In theory, you could implement it through power automate or js code automatically, but in practice it's not realistic because there are many types of activities.

    pastedimage1628835529227v1.png

    If you want to use power automate, you need set trigger on these entities, If you want to use js, you need load code in the form on these entities, Both are a lot of work.

    Personally, it's easier for you to do it manually!

    When you create a new activity for one opportunity, you can filter all activities related to the opportunity in Advanced Find, check all activity records except newly created, then click 'Mark Complete' button.

    pastedimage1628835993417v2.png

    Regards,

    Leah Ju

    Please mark as verified if the answer is helpful. Welcome to join hot discussions in Dynamics 365 Forums.

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

🌸 Community Spring Festival 2025 Challenge 🌸

WIN Power Platform Community Conference 2025 tickets!

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Kudos to the February Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 293,302 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 232,114 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156 Moderator

Leaderboard

Product updates

Dynamics 365 release plans