i got a client side javascript function which is triggered on a button click (basically, its a calculator!!). Sometimes, due to enormous data on the page, the javascript cal
For the loading message, I would use a When you want to show the loading indicator, you're going to have to use a timeout otherwise the Because you set the timeout, the page will redraw before the time-consuming loop happens.position:absolute, position it using left and top, and set the display to none.
div won't display until your processing is done. So, you should modify your code to this:function showLoadingIndicator()
{
// Display div by setting display to 'inline'
setTimeout(CalculateAmountOnClick,0);
}
function CalculateAmountOnClick()
{
// MY time consuming loop!
{
}
// Remove transparent div
}