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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T03:26:05+00:00 2026-05-14T03:26:05+00:00

I have a very simple MVC site that is returning a 404 not found

  • 0

I have a very simple MVC site that is returning a 404 not found error when trying to load a page at the very beginning. I’m looking for some direction to troubleshoot this problem since there is really nothing to go on from the error message.

UPDATE: The problem appears to have been cause by me setting the start page by right-clicking on the file and saying set as start page. This caused Visual Studio to try to load that page directly. When modifying the url to access the page using the routing rules the page will load correctly as suggested by Keltex below.

The error I’m getting is:

Description: HTTP 404. The resource you are looking for (or one of its
dependencies) could have been removed, had its name changed, or is temporarily
unavailable. Please review the following URL and make sure that it is spelled
correctly.

Requested URL: /Views/Other/Index.aspx

Below I have included the code for the various pieces, routing rules are default:

routes.MapRoute(
    "Default", // Route name
    "{controller}/{action}/{id}", // URL with parameters
    new { controller = "Home", action = "Index", id = UrlParameter.Optional}  // Parameter defaults
);

The site is using nested MasterPages, not sure if this is involved with the problem but trying to include as much detail as possible.

I have:

Controllers

  • OtherController

Views:

  • Shared Folder:
    • Site.Master
  • Other Folder:
    • Other.Master
    • Index.aspx

Site.Master Code:

<%@ Master Language="C#" Inherits="System.Web.Mvc.ViewMasterPage" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
    <head runat="server">
        <title>
            <asp:ContentPlaceHolder ID="TitleContent" runat="server" />
        </title>
    </head>
    <body>
        <div>
            <asp:ContentPlaceHolder ID="MainContent" runat="server">
            </asp:ContentPlaceHolder>
        </div>
    </body>
</html>

Other.Master Code:

<%@ Master Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewMasterPage" %>

<asp:Content ID="OtherTitle" ContentPlaceHolderID="TitleContent" runat="server">
    OTHER PAGE - MASTER TITLE
    <asp:ContentPlaceHolder ID="OtherPageTitle" runat="server">
    </asp:ContentPlaceHolder>
</asp:Content>

<asp:Content ID="OtherContent" ContentPlaceHolderID="MainContent" runat="server">       
    Some other content.
    <asp:ContentPlaceHolder ID="PageContent" runat="server">    
    </asp:ContentPlaceHolder>
</asp:Content>

Index.aspx Code:

<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Other/Other.Master" Inherits="System.Web.Mvc.ViewPage" %>

<asp:Content ID="IndexTitle" ContentPlaceHolderID="OtherTitle" runat="server">
    Home
</asp:Content>

<asp:Content ID="IndexContent" ContentPlaceHolderID="OtherContent" runat="server">
    Index content
</asp:Content>

OtherController Code

namespace MVCProject.Controllers
{
    public class OtherController : Controller
    {
        //
        // GET: /Member/

        public ActionResult Index()
        {
            // Have also tried:
            // return View("Index", "Other.Master");

            return View();
        }
    }
}
  • 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-14T03:26:06+00:00Added an answer on May 14, 2026 at 3:26 am

    I think the URL should be:

    /Other
    

    not

    /Views/Other/Index.aspx
    

    The URLs are not typically prefixed with /Views. This is just the folder in which views are located. Also typically the View Index is not specified since this is the default action. Finally the extension .aspx is usually not specified in MVC. If you want this page to come up as the site’s default page, you need to change your routing rules to look like this:

    routes.MapRoute(
        "Default", // Route name
        "{controller}/{action}/{id}", // URL with parameters
        new { controller = "Other", action = "Index", id = UrlParameter.Optional}  // Parameter defaults
    );
    

    (notice the change of the default controller from Home to Other)

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

Sidebar

Related Questions

I have a very simple ASP.Net page that acts as a front end for
I'm building a very simple ASP.NET MVC site that doesn't require a database and
I have an ASP.Net MVC Page with a very simple form on it: One
I have put together a small ASP.NET MVC 2 site that does some very
i have very simple problem. I need to create model, that represent element of
I have a very simple bit of script that changes the status of an
I have a very simple Java RMI Server that looks like the following: import
I have written a VERY simple MVC application which just displays a single string
I'm developing a web application using a very simple (maybe not really MVC-compliant) MVC
So I am very new to web development and have a .NET MVC site

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.