Tag: Route

  • Changing default route in ASP.NET MVC

    Hello friends, As we know that ASP.NET MVC by default takes following setting available in RouteConfig file (under App_Start folder). routes.MapRoute( name: “Default”, url: “{controller}/{action}/{id}”, defaults: new { controller = “Home”, action = “Index”, id = UrlParameter.Optional } ); This means when you run the application, Home controller will be invoked and it’s Index method will be executed by taking parameter id (if any). you can change…