web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Customer experience | Sales, Customer Insights,...
Answered

Appointments - Required Attendees field

(0) ShareShare
ReportReport
Posted on by 220

Hello,

I need the 'Required Attendees' field on the appointment form to be editable once an appointment has been marked complete. For other fields on the appointment form I have used a business rule to unlock these fields if the status is 'Completed'.

However, the Required Attendees field is not visible to select for a business rule, any ideas how I can achieve this?

Thank you

Ladga

I have the same question (0)
  • Verified answer
    LuHao Profile Picture
    40,892 on at

    Hi Ladga,

    The reason why the Required Attendees field is not visible in the business rule is that it is a Party List type field.

    pastedimage1597289546970v1.png

    So, in order to unlock the Required Attendees field, we have to use Javascript.

    Here are steps.

    Edit the Appointment form, open the Form Properties.

    pastedimage1597298030743v2.png

    Add a form library.

    pastedimage1597298098302v3.png

    New a web resource, select Type to Script. Edit the text to the follow. Then publish it. Add the new web rescource.

    pastedimage1597298185467v4.png

    function unlockfield(executionContext) 
    {
        var formContext = executionContext.getFormContext();
        var headerControl = formContext.getControl('header_statecode');
        var status = headerControl.getAttribute().getText();
        if(status=="Completed")
        {
            formContext.getControl("requiredattendees").setDisabled(false);
        }
    }

    Add a OnLoad event.

    pastedimage1597298319138v5.png

    Type function to unlockfield. Select "Pass execution context as first parameter".

    pastedimage1597298387887v6.png

    Save and publish the form.

    When we open an appointment which is completed, the Required field is editable, we can save the change of this field.

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Customer experience | Sales, Customer Insights, CRM

#1
Tom_Gioielli Profile Picture

Tom_Gioielli 108 Super User 2025 Season 2

#2
Jimmy Passeti Profile Picture

Jimmy Passeti 50 Most Valuable Professional

#3
Gerardo Rentería García Profile Picture

Gerardo Rentería Ga... 49 Most Valuable Professional

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans