Posts tagged errors

There are 3 posts for the tag errors

Subtle differences

This post was originally published on http://labs.dropit.se/blogs. Today I hade the dubious pleasure of having to work with an old EPiServer 4 site, and having to deploy it to IIS7 on a Windows 2008 Server. In order to make everything work in EPiServer 4, you need to make sure that all 404-request are redirected to /Util/NotFound.aspx. On my development machine, which runs Windows 7, I accomplished this by adding the following code to web.config: <system.webServer> <httpErrors...

Posted by johan on August 26, 2009

Most misleading error message ever?

This post was originally published on http://labs.dropit.se/blogs. Sometimes .NET error messages are helpful, sometimes they are not. But worst of all are when they are outright misleading! Like the one I came across today. I was trying to programmatically register a ASP.NET Ajax ScriptManager in a web control, and as the webcontrol was already overriding OnPreRender, I figured “what the heck, I’ll just put it there”. So, I basically wrote this code: protected override void OnPreRender( Ev...

Posted by johan on July 08, 2009

Simple Exception logging with ELMAH

This post was originally published on http://labs.dropit.se/blogs. Logging errors on a web site can be a pain. Sure, when you use EPiServer, you get the log4net error logging framework, but how much fun is it to read the log files it produces? First, every 404 is going to clog the log file making the important errors hard to find and second, the format of the log is not really reader friendly – you need to access the server and open it in a text editor. This usually means that you (or I, or we...

Posted by johan on April 19, 2009