Loading icon appearing and disappering

In our code, we are looping each record while clicking on expand button. if there is 5 records inside this and on clicking on "Expand All", 5 times, loading icon is coming and going.

Need to make this loading icon appear all time, till all 5 records get expanded!

Please give some solution!!

Hi Krishna,

Can you explain a bit more what the "Expand All" (button? link?) actually does?... a screenshot along with the explanation would be helpful.

If you see a loading icon displayed 5 consecutive times, it seems you're doing 5 independent Ajax requests, where you most likely just wanted one that expands (how are you implementing this?) the 5 records in one go...

can you post the code?