Showing posts with label set default page in asp.net mvc. Show all posts
Showing posts with label set default page in asp.net mvc. Show all posts

Set default page in Asp.Net MVC

In the project ->  App_Start ->  RouteConfig.cs 


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

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