0

Hi guys i added a html file to my project in MVC ,and i set this page as a start up ,and now i want to change my default route to another view in MVC .

So i added this code to my global.asax but it didn't work :

 public class RouteConfig
{
    public static void RegisterRoutes(RouteCollection routes)
    {
        routes.IgnoreRoute("{resource}.axd/{*pathInfo}");

        routes.MapRoute(
            name: "Default",
            url: "{controller}/{action}/{id}",
            defaults: new { controller = "Account", action = "login", id = UrlParameter.Optional }
        );
    }
}

Any idea .Thank you

Ehsan Akbar
  • 6,977
  • 19
  • 96
  • 180

0 Answers0