Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3975432
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T04:41:04+00:00 2026-05-20T04:41:04+00:00

I am trying to get an ASP.Net MVC2 app to display a simple custom

  • 0

I am trying to get an ASP.Net MVC2 app to display a simple custom error rather than the yellow screen. I have already set up elmah to silently log the error in the background but while that happens I want to display a simple static error message based on the view in Shared/Error.aspx. Nothing fancy, just a plain vanilla “there was an error”.

<customErrors mode="On" defaultRedirect="~/Error.aspx" />

I thought this was simply a matter of adding a customError tag to my config but I am still seeing the yellow page. Do I have to write a custom action handler for the Error.aspx view before I can use it? Could this be due to some interaction with elmah?

Thanks!
Duffy

Update: It seems that the problem is NInject getting in the way of handling a static error page. The yellow sceen error I am seeing is not for the original error message but the NInject Factory not finding a controller for error.aspx.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-20T04:41:05+00:00Added an answer on May 20, 2026 at 4:41 am

    I still have no idea why failed to find my static error files. However, I finally got around the problem by defining an error controller and changing my web.config to this instead.

     <customErrors mode="On" defaultRedirect="/Error/GenericError" />
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a hard time in asp.net MVC2 trying to get the checked values
I'm trying to get an understanding of how to structure an ASP.Net MVC2 Web
I'm trying to write REST-behaviour into my ASP.NET MVC2 app, but I'm having a
I've trying to get an ASP.net (v2) app to work in the debugger and
Trying to get Nunit working in ASP.Net. The problem is, I'm testing a custom
I am having problems trying to get a very simple ASP.Net application to start
I am trying out some globalization in an asp.net mvc2 application but can't get
I am trying to get ASP.Net MVC 4 working on IIS6 and am running
I am trying to get a ASP.NET Unit Test running and I keep getting
I'm trying to get the new ASP.NET Web API beta (VS 2010 default Web

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.