Al Pascual



Geo RSS
Geo Twitter Timeline

Blogs I read

<December 2008>
SunMonTueWedThuFriSat
30123456
78910111213
14151617181920
21222324252627
28293031123
45678910

Code Snip "Customizing ScriptManager" to detect errors

 Quick code snip that you should add to your script manager if you are using AJAX to catch errors, something pretty frequent when using the ajax library.

aspx.cs:

 protected void ScriptManager1_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
    {
        ScriptManager1.AsyncPostBackErrorMessage = e.Exception.Message+e.Exception.StackTrace ;
    }

aspx:

<asp:ScriptManager ID="ScriptManager1" runat="server"
            OnAsyncPostBackError="ScriptManager1_AsyncPostBackError">
            </asp:ScriptManager>


There are many customizations on the ScriptManager.

Comments

Community Blogs said:

On the ArcGIS server development blog you&rsquo;ll find a much waited post; how to use ASP.NET AJAX and

# April 4, 2007 12:02 AM

DotNetKicks.com said:

You've been kicked (a good thing) - Trackback from DotNetKicks.com

# April 10, 2007 11:04 PM

Community Blogs said:

Most annoying issue with MS ASP.NET 2.0 Ajax 1.0 is the error Sys.WebForms.PageRequestManagerParserErrorException

# April 27, 2007 12:05 AM

Community Blogs said:

Last year I wrote a fix for AJAX 1.0 on my old blog, looks like many people found it helpful, I wanted

# April 23, 2008 2:46 AM

Dharma said:

hi , thanks for ur solution, i got head ache with that error,am very greatfull and thankful to u Regards, dharma
# April 24, 2008 7:19 AM

Monty said:

After adding that code, it just hid my error. Thought it would detect something?
# May 16, 2008 1:07 AM

Musa Bhai said:

enableEventValidation="False" Adding this it doesn't make any diff. My actual problem is in Login window. If the Login or password entered wrong it shows the appr. message and allows to enter again, but entering again and click on login gives this error. "Sys.WebForms.PageRequestManagerParserErrorException"
# July 7, 2008 4:33 AM