I want to use Xrm.Utility.confirmDialog
but I need to edit the button's text, is it optional ? if yes, how can I do that ?
Asked
Active
Viewed 533 times
1

Arun Vinoth-Precog Tech - MVP
- 22,364
- 14
- 59
- 168

Damkulul
- 1,406
- 2
- 25
- 59
-
Any follow up questions? – Arun Vinoth-Precog Tech - MVP Aug 07 '21 at 00:20
2 Answers
1
The previous version Xrm.Utility.confirmDialog does not have an option to customize the button label text. And its deprecated too.
Based on your CRM 2016 version - we don't have any supported way to achieve it.
Whereas the latest version Xrm.Navigation.openConfirmDialog is having that option to customize the button label text.

Arun Vinoth-Precog Tech - MVP
- 22,364
- 14
- 59
- 168
1
Further to @Arun Vinoth's answer, the JS to edit the button's text would look similar to:
const confirmStrings = {
cancelButtonLabel: "Cancel this change" // Cancel button text
confirmButtonLabel: "Confirm this change" // Confirm button text
};
Xrm.Navigation.openConfirmDialog(confirmStrings).then(...
You didn't specify which button you wish to edit, so both are included.

Corey Sutton
- 134
- 3