ASPNET Custom Errors Server.GetLastError() is null


Problem: Getting custom error page to present the exception thrown

Behavior: both Server.GetLastError() and Server.GetLastError().GetBaseException() return null

Solution: add redirectMode with ResponseWrite value

 

Update: A few interesting troubleshoot data:
  • Environment.Machine
  • DateTime.UTCNow.ToString()
  • Request.Browser.Browser
  • Request.Browser.Version
  • Request.Url.ToString()
  • Server.GetLastError().GetBaseException().Message.ToString()
  • Server.GetLastError().GetBaseException().GetType().ToString()
  • Server.GetLastError().GetBaseException().StackTrace.ToString()

http://stackoverflow.com/questions/343014/asp-net-custom-error-page-server-getlasterror-is-null

Comments

Popular posts from this blog

Breaking down document locking in SharePoint

Working around X-Frame-Options for iframes

Document ID not being generated