AJAX, Technology

Response.Redirect not working within an UpdatePanel?

If you get an exception when doing a Response.Redirect within an UpdatePanel then you are most probably missing the following lines in your web.config:

<httpModules>
  <add name="ScriptModule" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
</httpModules>
AJAX, Technology

Create a global progress bar for your ASP.NET AJAX applications

In ASP.NET AJAX you can use the UpdateProgress control to display a progress bar for asynchronous page updates. This control needs to be attached to a single UpdatePanel. If you need a consistent progress bar throughout your application, you will thus need to add one UpdateProgress control for every UpdatePanel control. Since this is not an ideal solution, then instead of using the UpdateProgress control, we can create our own progress bar by attaching a method to the beginRequest and endRequest event of the PageRequestManager class, which toggles the visibility of a div-container with an animated image. Have a look at the example below. Read More »