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

Community site session details

Session Id :
Customer experience | Sales, Customer Insights,...
Suggested answer

XRM showprogressindicator function not work

(2) ShareShare
ReportReport
Posted on by 6
I want to show the progress indicator after user confirm. But it not work now .  And I was tested  the other function( alterDialog ) of XRM, it's useful. What's the issue with my code?
issue.js

Your file is currently under scan for potential threats. Please wait while we review it for any viruses or malicious content.

I have the same question (0)
  • tmeloooo Profile Picture
    6 on at
    XRM showprogressindicator function not work
    this.DraftBatchDelete = function (ID, primaryCtrl) {
        debugger;
        var confirmStrings = { text: "Are you sure you want to remove?", title: "Confirm" };
        var confirmOptions = { height: 200, width: 450 };
        var msg = "";
        var selectedIds = ID;
        var blCanSubmit = true;
        var selectedRows = primaryCtrl.getGrid().getSelectedRows();
        console.log("choose" + selectedRows.getLength() + " records.");
        if (selectedRows.getLength() === 0) {
            msg = "Please select at least one item!";
            blCanSubmit = false;
        }
        if (blCanSubmit) {
            Xrm.Navigation.openConfirmDialog(confirmStrings, confirmOptions).then(
                function (success) {
                    if (success.confirmed) {
                        Xrm.Utility.alertDialog("Removing data, please wait...");  // useful
                        Xrm.Utility.showProgressIndicator("Removing data, please wait...");//not work
     
                        selectedRows.forEach(function (row, i) {
                            var entityId = row.getData().entity.getId().replace('{', '').replace('}', '');
                            var entity = {};
                            entity.statecode = 1;
     
                            Xrm.WebApi.online.updateRecord("crb94_xxxxxx", entityId, entity).then(
                                function success(result) {
                                    var updatedId = result.id;
                                    console.log(updatedId);
     
                                    parent.window.location.reload();
                                },
                                function (error) {
                                    Xrm.Utility.alertDialog(error.message);
                                }
                            );
                        });
     
                        Xrm.Utility.closeProgressIndicator();
                    }
                }
            );
        }
        else {
            Xrm.Utility.alertDialog(msg);
        }
    }
  • Suggested answer
    Amit Katariya007 Profile Picture
    10,409 Super User 2025 Season 2 on at
    XRM showprogressindicator function not work
    Not able to see attachment.
    Please share your code along with image.

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…

Mansi Soni – Community Spotlight

We are honored to recognize Mansi Soni as our August 2025 Community…

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Customer experience | Sales, Customer Insights, CRM

#1
Hamza H Profile Picture

Hamza H 141

#2
Daniyal Khaleel Profile Picture

Daniyal Khaleel 132

#3
DAnny3211 Profile Picture

DAnny3211 130

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans