Skip to main content

Notifications

Announcements

No record found.

Dynamics 365 general forum

Dynamics 365 Customer Engagement Unified UI Javascript issues

(0) ShareShare
ReportReport
Posted on by 280

Hello,

 

We are facing couple of JavaScript issues on the unified UI for Dynamics 365 Customer Engagement.

 

  1. When using Flip-Switch control instead of standard checkbox control, the onChange event on the field does not trigger
  2. The Form Save event execution doesn’t acknowledge the Ok/Cancel input from the user on the confirmation dialog box. Saves the form anyway

Any help on resolving these issues will be much appreciated. This is hindering our progress to migrate from the Classic UI to the Unified UI.

 

Thanks,

Swaroop

  • Suggested answer
    Henry J. Profile Picture
    Henry J. 5,237 on at
    RE: Dynamics 365 Customer Engagement Unified UI Javascript issues

    For #1 Business Rules also trigger on change, but that doesn't solve your JavaScript issue. Please reach out to support for guidance.

    For #2 Can you modify your business logic to first prompt for confirmation from the user and based on the output (confirmation) only then trigger the save?

    In any case, you should use Xrm.Navigation for your dialog, as other methods are officially deprecated, as documented here:

    docs.microsoft.com/.../xrm-utility

  • Swaroop Deshmukh Profile Picture
    Swaroop Deshmukh 280 on at
    RE: Dynamics 365 Customer Engagement Unified UI Javascript issues

    Hi Henry,

    For both #1 and #2 I am using Javascript functions which work correctly on the Classic UI.

    For #1

    I have a javascript function that triggers on the OnChange event. When I change the control to use Flip-switch instead of a checkbox, by flipping the value NO to YES or YES to NO doesnt trigger my javacscript on change function.

    I cannot use a Business Rule in this case as I am expecting the functionality to work on change. With business rule i can only make it run on save.

    For #2

    This is also a custom javascript function that opens up a confirmation dialog box before the save action completion, takes the input from user to proceed with the save or cancel the save and then based on the input provided completes the save action or prevents the save action. I am using the Xrm.Utility confirm dialog box for this which works correctly in the classic UI.

    I also tried using the Xrm.Navigation confirm dialog box but have seen the same behavior. The save action always completes irrespective of the input from the user (even before the user provides any input).

    Thanks,

    Swaroop  

  • Suggested answer
    Henry J. Profile Picture
    Henry J. 5,237 on at
    RE: Dynamics 365 Customer Engagement Unified UI Javascript issues

    Hi Swaroop,

    For #1 that's odd. Are you using a Business Rule or a JavaScript for this?

    In case you are using a Business Rule, can you check if all the fields referenced in the Business Rule logic are present in the form body?

    For #2 is this a Save that you are doing in JavaScript?

    Otherwise in my experience the Unified Interface does take into account the user choice to either save or discard their changes.

    Did you have the opportunity to test the Early Access of the Release Wave 2 on a sandbox?

    Because this enhancement might be of interest to you: docs.microsoft.com/.../improving-save-changes-dialog

    You can activate the Early Access by following these steps: docs.microsoft.com/.../preview-october-2019-updates

    In case you still have issues for both #1 or #2, I'd recommend that you open a Support Request here: admin.powerplatform.microsoft.com/support

    Henry

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 Coming on 11/8!

In our never-ending quest to help the Dynamics 365 Community members get answers faster …

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,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

Featured topics

Product updates

Dynamics 365 release plans