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

  • Home
  • SEARCH
  • 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 9168461
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T15:37:52+00:00 2026-06-17T15:37:52+00:00

I have an area in my Mvc solution called /Admin Within the /Admin/Views folder

  • 0

I have an area in my Mvc solution called /Admin

Within the /Admin/Views folder there is a standard web.config file.

I have included in this config file a customerErrors element under the system.web:

<customErrors mode="On" defaultRedirect="~/admin/oops" >  
  <error statusCode="404" redirect="~/admin/pagenotfound"/>
</customErrors>

Which differs from the one in my root web.config.

My expectation was that this would give me specific control of how errors are dealt with in the admin area.

This isn’t working.

Am I taking crazy pills or should I be able to override the default web.config settings with a more specific one in the area’s web.config?

  • 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-06-17T15:37:53+00:00Added an answer on June 17, 2026 at 3:37 pm

    Actually here is an article written about areas in mvc.

    AREAS in ASP.NET MVC

    According to this article, we cannot override the settings..

    Web.Config in Views folder
    Pages also called views are available in the views folder. In MVC views are not directly exposed to outside by URLS. All the view requests should go to the controller and it will render the exact view using the inputs from URL. Views are normal asp.net web pages, so they can be accessible a URL. To restrict direct accessing of views, we use web.config file in views folder. The web.config has a default handler mapping to blocks all the pages which has extension ASPX.

    Web.Config in Area folder
    Similarly for views, there is a web.config file for each area serving the same purpose. This is to restrict access of ASPX files. If we don’t want to restrict them at area Level, we can delete this web.Config file.

    Application settings in Web.Config
    There are many web.config files; can we have application settings of areas in area specific web.config file? The answer is No, we cannot or have or override the appsettings configurations. All the application settings should be defined in the web.config of the root folder

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an Area called Admin. The folder structure in Visual Studio is this:
I've setup an Admin area within MVC 3 application and while everything is working
In asp.net mvc 3, If I have an area called MyArea, how would I
I have an ASP.NET MVC 3 application (in IIS 7.5) with a portable area.
I have a MVC 2 site with an area, let's say the area name
I have to build 3 MVC web applications using Entity Framework (www.company1.com www.company2.com www.company3.com).
I have an .Net MVC 3 web application that has the following structure root
I have a solution with a fair few projects, 3 of them web-based (WCF
I have a MVC web application. Lets call it Parent website. In order to
I have added an area to my MVC 3 project. I cannot seem to

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.