ASP.NET MVC5 The webserver is not configured for the requested URL, and directory browsing is not enabled on the server

后端 未结 5 503
终归单人心
终归单人心 2021-01-05 16:46

I have an issue with loading the pages from a MVC5 application.

I have this software installed and used:

  • Windows 10
  • Visual Studio Enterpris
5条回答
  •  南笙
    南笙 (楼主)
    2021-01-05 16:49

    My problem went away once I added a specific map route to RouteConfig.cs in the App_start folder

    'routes.MapRoute("Buy lands", // string name "BuyLands/Index", // string Url new { controller = "BuyLands", Action = "Index" });

    // controller name is BuyLands'

提交回复
热议问题