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

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

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

Show progress indicator not appearing when I run my code

(0) ShareShare
ReportReport
Posted on by 92

Hello,

I hope someone can help me with my problem.

I created a javascript that calls a process to run a plugin, meanwhile, I added

Xrm.Utility.showProgressIndicator("Processing..."); to show a loading screen as the plugin executes.

I will add an attachment of my code so you may see where I am showing and closing the progress indicator.
The problem is that the code was working fine and suddenly it stopped showing the progress indicator.
I tried to debug my to check the error but Xrm.Utility.showProgressIndicator("Processing..."); is returning undefined and I guess it is working.
I hope someone can help me and assist me to show the progress bar indicator.
I am showing the progress indicator on line 2.
Closing it on lines 52 and 98.
[View:/cfs-file/__key/communityserver-discussions-components-files/117/HireOnClick.js:320:240]
pastedimage1671612724964v2.gif
 
Thank you!
I have the same question (0)
  • Suggested answer
    Abdul Wahab Profile Picture
    12,119 Moderator on at
  • MBaba Profile Picture
    92 on at

    Hello Abdul Wahab ,

    Thank you for your help.

    I have already read these blogs and checked them, yet its still not working.

    As you can see in my GIF it is returning undefined, as it should, but the loading UI is not appearing.

    Thank you!

  • LC-27040918-0 Profile Picture
    2 on at
    Not sure if you have resolved this issue. The first problem appears to be the logic of the code itself. As the debugger shows, setting the "res" variable to the "showProgressIndicator" statement means "res" will always be undefined. So the While loop never starts.

    Similar to the OP's issue, the second problem has to do with the indicator displaying; but my problem was the indicator started only after the plugin logic finished.

    To get around this, I wrapped the main logic of the JavaScript in the setTimeout callback. I put the "closeIndicator" function in the plugin request callback as part of the main function logic.
     
    function CallCustomActionFromJavaScript(primaryControl){
    debugger;
    
        Xrm.Utility.showProgressIndicator("Custom Message");
        setTimeout(mainFunction, 1000);
        
        function mainFunction(){}
    }
     

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Meet the Microsoft Dynamics 365 Contact Center Champions

We are thrilled to have these Champions in our Community!

Congratulations to the April Top 10 Community Leaders

These are the community rock stars!

Leaderboard > Customer experience | Sales, Customer Insights, CRM

#1
ManoVerse Profile Picture

ManoVerse 101 Super User 2026 Season 1

#2
11manish Profile Picture

11manish 72

#3
Muhammad Shahzad Shafique Profile Picture

Muhammad Shahzad Sh... 69 Most Valuable Professional

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans