web.config: redirect to a url for a status code
<configuration> <system.web> <customErrors defaultRedirect="userError.aspx" mode="RemoteOnly"> <error statusCode="404" redirect="pagenotfound.aspx" /> </customErrors> </system.web> </configuration>