Xrm.Navigation Client API Methods
The Xrm.Navigation Client API namespace is included in Microsoft Dynamics 365, version 9.0 as part of the Xrm Object Model. It provides seven methods for navigating Dynamics 365 and displaying dialogs. This blog post will give you a quick overview of the Xrm.Navigation Client API Methods so that you can begin using them in your own projects.
This method displays a customisable alert dialog containing a message and a confirm button. The labels of the button can be customised, and the height and width of the alert dialog box can be altered.
Xrm.Navigation.openAlertDialog(alertStrings,alertOptions).then(closeCallback,errorCallback);
Displays a confirmation dialog box containing text, a cancel button, and a confirm button. The labels of the buttons can be customised, and the height and width of the confirmation dialog box can be altered.
Xrm.Navigation.openConfirmDialog(confirmStrings,confirmOptions).then(successCallback,errorCallback);
This method displays a customisable error dialog. The error details can be changed to give more information to users working with Dynamics 365.
Xrm.Navigation.openErrorDialog(errorOptions).then(successCallback,errorCallback);
By default, this method opens a file, but it can also save files by changing the openFileOptions parameter.
Xrm.Navigation.openFile(file,openFileOptions);
Opens an entity form or a quick create form. This method is a replacement for the deprecated Xrm.Utility.openEntityForm and Xrm.Utility.openQuickCreate methods.
Xrm.Navigation.openForm(entityFormOptions,formParameters).then(successCallback,errorCallback);
This method opens a URL, including URLs for files. This is particularly useful for opening a URL in a browser from a mobile client.
Xrm.Navigation.openUrl(url,openUrlOptions);
This method opens a HTML web resource, and is a replacement for the deprecated Xrm.Utility.openWebResource method.
Xrm.Navigation.openWebResource(webResourceName,windowOptions,data);
*This post is locked for comments