When you use an UpdateProgress control, it will appear every time the UpdatePanel it's associated with is involved with an Ajax Call the server.
If you don't want it to appear every time then you should not use the UpdateProgress control.
At the time that I answered your question I thought the UpdateProgress control was part of the Ajax Control Toolkit. Are you using the
Ajax Control Toolkit in your application? Animations are not available without this toolkit....
If you're not using the Ajax Control Toolkit consider implementing JavaScript function to handle the
PageRequstManager's BeginRequest and EndRequest events (info on the BeginRequest Event can be found
here and info on the EndRequest Event can be found
here.
You would have 2 JavaScript functions that handle these events:
-
function BeginRequestHandler(){
-
'code that displays the <div> during updating
-
}
-
function EndRequestHandler(){
-
'code that hides the <div> when not updating.
-
}
The PageRequestManager has a Singleton pattern. You get a reference to the PageRequestManager using the getInstance() method. Once you have this reference you can tell it to execute the JavaScript methods when the request begins and ends:
-
Sys.WebForms.PageRequestManager.getInstance().add_beginRequest(BeginRequestHandler); Sys.WebForms.PageRequestManager.getInstance().add_endRequest(EndRequestHandler);
-Frinny