Overview of Routing in Asp.Net MVC with Example

Overview of Routing in Asp.Net MVC with Example:

What is Route Table ?

The Route Table is a class that stores the URL routes for your application.


Depending upon the URL request by user using UrlRoutingModule find URL in Route table for creating RouteData object. If UrlRoutingModule find correct match then it goes to create RequestContext and then it forward the request to appropriate MVCHandler. Once MVCHandler receive request it invokes execute method on the Controller.

The Execute() method gets the Action from the RouteData based on the requested URL. Then MVC Controller will call Controller ActionInvoker which creates a list of parameters coming with URL this parameter list will be passed to Controller Action method. It calls InvokeAction method to execute action. Finally send response to browser.


Other Related Post:


Comments