Skip to main content

Notifications

Microsoft Dynamics CRM (Archived)

How can I create popup alerts as part of a workflow process?

Posted on by 405

I have a workflow that sends an email containing values from several fields. However, if the fields are blank or don't meet certain criteria, I want the workflow to stop, and most importantly, I want an alert to be displayed that lets the user know (preferably in real time) that the workflow is going to be canceled, and they should go back and correct those fields. To put it another way, I want conditional alerts, i.e., if certain conditions are present, I want to display an alert to the user. Ideas?

*This post is locked for comments

  • Suggested answer
    Franco Prussian Profile Picture
    Franco Prussian 405 on at
    RE: How can I create popup alerts as part of a workflow process?

    Thank you both for the suggestions. You gave me some good ideas that led to final solution: I used conditional statements in the workflow, so if the right conditions are not present, it will stop the workflow as canceled. I put a custom message into the cancellation properties so that when the workflow stops, CRM displays an alert which tells the user why it failed. I am using a real time workflow.

  • Aileen Gusni Profile Picture
    Aileen Gusni 44,522 on at
    RE: How can I create popup alerts as part of a workflow process?

    Franco,

    If you are using CRM 2013 and above you can have Real Time workflow that can help you validate the process and cancel it if the fields are blank or don't meet certain criteria.

    Making the field as mandatory might be a solution to you prompt user that should key in this field, but in some point this field is not necessary to set as mandatory, for example you have case: if Account industry is IT then you need to make sure that the salesperson key in the Number of Consultant, for example, by making it as mandatory.

    If Account industry is Agriculture then the Number of Consultant field of course is not mandatory, instead, maybe you need another number like total size of field in hectare or who is their Farm Supplier, etc. And if Account industry is Food then you need Best Chef Name, for instance only.

    So the conditions is can be various. Which you can use Business Rule or JavaScript as well.

    But, if you already create your own process in the workflow, then you can utilize workflow for validation purpose.

    Here are the useful example:

    garethtuckercrm.com/.../crm-2013-new-features-using-real-time-workflow-for-validation-rules

    nakedcrm.wordpress.com/.../using-workflows-to-validate-records-to-prevent-creates-updatesassign-and-deletes

    It will help to prompt user based on certain conditions + cancel the workflow as well, meaning that not finishing the execution as completed.

    But there are things you need to aware that the prompt only works for Real Time Workflow, otherwise it would only cancel the workflow without notification, and if you are not using CRM 2011 and above, you cannot have this feature, then it will only triggered in some condition after save, for example field change, created, etc based on workflow trigger point. And you cannot have condition based on child records.

    Hope this helps.

    Thank you.

  • Suggested answer
    Mithilesh Kumar Profile Picture
    Mithilesh Kumar 10,045 on at
    RE: How can I create popup alerts as part of a workflow process?

    Hi Franco,

    Since you are talking about making fields mandatory, I would not suggest to make them using the OOB functionality.

    You can make the fields Business Required. This will not allow the user to Save the record until those fields are entered.

    You can also check the criteria for the fields using JScript and if the condition is not met you can alert the User to correct those fields.

    Since Workflow has trigger point you can always stop them to hit by not Saving the record.

    Hope that helps

    Thanks

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

November Spotlight Star - Khushbu Rajvi

Congratulations to a top community star!

Forum Structure Changes Complete!

🔔 Be sure to subscribe to the new forums you are interested in to stay up to date! 🔔

Dynamics 365 Community Platform update – Oct 28

Welcome to the next edition of the Community Platform Update. This is a status …

Leaderboard

#1
André Arnaud de Calavon Profile Picture

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

#2
Martin Dráb Profile Picture

Martin Dráb 229,918 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans