Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

How Refresh the Form after Dialog process is finished

(0) ShareShare
ReportReport
Posted on by 3

Hi,

on my CRM D365 v9.1.x I want mantain a Dialog (MS wants to deprecate it not remove it today, so I don't want I don't want to confuse final users with the use of a new BPF or a new Flow). I call dialog by a custom Button on the Ribbon of the custom entity "pdnt_claim".

I call fine the Dialog by js:

function buttonClaim(primaryControl){

  var formContext = primaryControl;
  var dialogId = "947bd9f1-9df6-43ae-97c4-b9f58c332c08";
  var url = Xrm.Utility.getGlobalContext().getClientUrl() + "/cs/dialog/rundialog.aspx?DialogId=%7b" + dialogId + "%7d&EntityName=pdnt_claim&ObjectId=" + formContext.data.entity.getId();
  Xrm.Navigation.openUrl(url, { height: 400 }); // I want call the new Xrm API and not deprecated commands like 'window'

 /* ...after the dialog is closed i want refresh the prevoius parent form... */


}


But after the Dialog is concluded (I click on Finish button) I would like refresh the form.

Using 

formContext.data.refresh(save)


after Xrm.Navigation.openUrl(..) return error.

Using:

window.parent.location.reload(true);

after Xrm.Navigation.openUrl(..) is incorrect.

I can't use setCallbackReference like in https://community.dynamics.com/crm/b/crmpowerobjects/archive/2017/03/21/triggering-a-form-refresh-after-crm-dialog-is-closed-on-dynamics-365

because call inconsistent system Mscrm object. Also showModalDialog() it's deprecated.

So there is a js object, MS API or workaround in order to resolve the refresh form after process dialog?

Someone has solved the question?

Outdated Idea: https://community.dynamics.com/crm/f/117/t/118457

https://community.dynamics.com/crm/f/117/t/77749

https://community.dynamics.com/crm/f/117/t/167173

https://stackoverflow.com/questions/39612832/dynamics-crm-2016-online-refresh-record-after-using-dialog




*This post is locked for comments

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

Announcing Our 2025 Season 1 Super Users!

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

Vahid Ghafarpour – Community Spotlight

We are excited to recognize Vahid Ghafarpour as our February 2025 Community…

Tip: Become a User Group leader!

Join the ranks of valued community UG leaders

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 292,516 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 231,321 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans