Skip to main content

Notifications

Announcements

No record found.

Customer experience | Sales, Customer Insights,...
Suggested answer

Is there an alternative? Pop up to warn that certain fields are required before closing Activity.

Posted on by 84

Hello, 

There are a set of fields that have to be filled to 'Yes' before marking the Activity as complete.

Options:

1. I dont want to make the field required, because they can take the time to do it.

2. If I set up a business rule, then there will be a popup all the time until the field is process - not a good user experience

3. Dynamics workflow as suggested by this article: https://www.crmsoftwareblog.com/2015/03/forcing-field-requirements-upon-closing-case-opportunity/ - I find that there must be a more user friendly experience than having 'Business process flow' pop up. 

Any one have any suggestions?

thank you,

  • Suggested answer
    Jenisha Dhas Profile Picture
    Jenisha Dhas 30 on at
    RE: Is there an alternative? Pop up to warn that certain fields are required before closing Activity.

    Hi Ikay,

    I reviewed your query regarding the alert popup message. In my opinion, making the field Required, is quite simple to implement and can be applied to any fields. Another option is to use JavaScript in that field.

    • Go to Power Apps solution.
    • Select the table in which the field is located.
    • Open the main form.

    pastedimage1673201333080v1.png

    • Open switch to classic mode.

    pastedimage1673201428136v2.png

    • Choose form properties and add new JavaScript library.

    pastedimage1673201474691v3.png

    • Create new JavaScript library and add this code.

    function lockLocationfield(executionContext)

    {

            var formContext = executionContext.getFormContext();

            var Companyeaddresstype = formContext.getAttribute("hud_test").getValue();

            if (Companyeaddresstype == null) {

              alert('Test field is Required');

            }

        }

    • After adding the code, call the on save function.
    • This code runs when you save the record and displays a popup warning if the field is empty.

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