Skip to main content

This content has been archived and is no longer being updated. Links may not function; however, this content may be relevant to outdated versions of the product.

Support Article

Show busy indicator on click of a pxButton

SA-17733

Summary



User wants to display busy indicator on click of a button.

ERROR MESSAGES

N/a

Steps to Reproduce



User has configured two buttons, on click of them they are running an activity and refreshing the current section. The activity invokes a service call. Expectation is busy indicator should always display.

ROOT CAUSE

User requirement.

Resolution



Perform the following local-change:

1)    Either in user work form or a text js file, write these functions
<script>
Test = function()
{
pega.u.d.busyIndInterval = 0;
pega.u.d.setBusyIndicator();
}

Hide = function()
{
pega.u.d.busyIndInterval = 2000;
if(pega.u.d.gBusyInd){
pega.u.d.gBusyInd.hide();
}
}
</script>

Ignore the script tags if you put it in the js file.  

2)    Add events “Run script” on the button and call the respective functions (Test and Hide)




Invoking sleep method to mimic delay

Published January 31, 2016 - Updated October 8, 2020

Was this useful?

0% found this useful

Have a question? Get answers now.

Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.

Did you find this content helpful?

Want to help us improve this content?

We'd prefer it if you saw us at our best.

Pega Community has detected you are using a browser which may prevent you from experiencing the site as intended. To improve your experience, please update your browser.

Close Deprecation Notice
Contact us