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 767159
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T17:09:58+00:00 2026-05-14T17:09:58+00:00

I am developing a website in MVC 2.0. I want to change the View

  • 0

I am developing a website in MVC 2.0. I want to change the View folder location in my website. I wanted to keep the views folder inside other folders, When I try to do so i am getting following errors

The view 'Index' or its master was not found. The following locations were searched:
~/Views/Search/Index.aspx
~/Views/Search/Index.ascx
~/Views/Shared/Index.aspx
~/Views/Shared/Index.ascx
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

My Views folder will be in ~/XYZ/ABC/Views instead of ~/Views. Please solve my problem. Will I get any problems If I change the default Views folder location. Do I need to change anything in HTML Helper classes because I don’t know anything in MVC as this is my starting project i dont want to risk..Please help me out…

  • 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-14T17:09:59+00:00Added an answer on May 14, 2026 at 5:09 pm

    You’ll need to create a custom view engine and use that instead. Fortunately you can just inherit from the default one and change the locations on the constructor. Here’s a guide to creating your own view engine: http://www.singingeels.com/Articles/Creating_a_Custom_View_Engine_in_ASPNET_MVC.aspx

    From the article:

    protected void Application_Start()
    {
        //... other things up here.
    
        // I want to REMOVE the ASP.NET ViewEngine...
        ViewEngines.Engines.Clear();
    
        // and then add my own :)
        ViewEngines.Engines.Add(new HoTMeaTViewEngine());
    }
    
    public class HoTMeaTViewEngine : VirtualPathProviderViewEngine
    {
        public HoTMeaTViewEngine()
        {
            // This is where we tell MVC where to look for our files. This says
            // to look for a file at "Views/Controller/Action.html"
            base.ViewLocationFormats = new string[] { "~/Views/{1}/{0}.html" };
    
            base.PartialViewLocationFormats = base.ViewLocationFormats;
        }
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm developing a website with ASP.NET MVC, NHibernate and Fluent NHibernate and want to
I'm developing my first MVC website and I'm experimenting with the few available grids
I'm currently developing a website in ASP .NET MVC and I require functionality for
I've been developing a simple website using asp.net MVC and I'm starting to add
i have a problem i am developing an asp.net mvc project. Website is in
Currently I am developing website in asp.net. I wanted to include spellchecker module into
What is mvc ? What are the benefits developing mcv website ? How can
What is difference of developing a website in MVC and 3-Tier or N-tier architecture?
I'm developing an website using asp.net mvc with MySQL and I need to make
I am developing a website in Asp.net MVC. I pass the HttpContext to the

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.