MVC Life Cycle – 6th Part

Hi Friends,

In this section, we will continue from the last section and the see the next segment of Action Execution Process. Here, in this case we will see Filters in action. Therefore, before the action method chosen, the Authentication and Authorization filter runs. Filters are nothing but MVC components to inject extra logic in between the MVC pipeline.Therefore, first authentication filter runs and if it succeeds then it will go to Authorization filter otherwise it will again ask user to re-authenticate. However, authorization is the filter which says are you allowed to access particular thing or not.

Read more

MVC Life Cycle – 5th Part

Hi Friends,

In this section, we will look at Action Execution event in the MVC life Cycle. Once, controller gets initialized then action invoker has to take decision saying which method to invoke and this piece is done by Action Invoker in the life cycle. Action Invoker based on different method signatures present in controller identifies the exact method to be invoked.

In the above snippet, there are two about methods. In this case, it has become ambiguous for action invoker to figureout to choose which method to pick and hence produced below error. 19th   However, this can be easily fixed by applying any HTTP Verbs or Action Selectors like shown below.  

Read more

MVC Life Cycle – 4th Part

Hi Friends,

In this section, we are going to see how Controllers are created and initialized.Basically, controllers does nothing but implement IController interface. IController defines one important method called Execute(). Also, it is important to note that this method is entirely generic which means you can build your controller in a more custom way specific to particular requirement. However, MVC is very powerful framework wherein all the concerns are already addressed. But, you can extend the default implementation for any specific need.

Read more

MVC Life Cycle – 3rd Part

Hi Friends,

In this section, we will continue from the previous point and delve further into MVC components. Here, in this case we will look at building custom handler. HTTPHandlers implement IHTTPHandler and generate a response to HTTP-Request. Therefore, we first need to create the Handler and then register the same with the application either through code or via config file. Now, IHTTPHandler exposes two properties.

Read more

MVC Life Cycle – 2nd Part

Hi Friends,

In this section, we are going to delve further around MVC Life Cycle. In the previous section, we have seen basic flow of MVC. However, let us consider the case, wherein you need to inject your custom module and wants to do logging extensively. In this kind of situation you want to execute some custom codes before actually the application starts. In order to achieve this kind of scenario, you need to make use of “PreApplicationStartMethod” @ assembly level. Below is the actual line of code of registering your custom module at PreApplicationStartMethod level.

Read more

MVC Life Cycle – 1st Part

Hi Friends,

In this section, I am going to describe MVC Life Cycle. If you are an MVC developer, then this entire flow should be in your DNA. This not only solves complex problem rather it also makes an app more robust, future proof, maintainable and testable. Below, I have pasted very high level diagram for the same. Therefore, without wasting time, let us get started.

1st

 

Read more

Learning Angular JS in 2 Hours – 3rd Part

Download Code:- https://github.com/rahulsahay19/movieReview-SPA-Demo However, if you would like to learn the stuffs from the scratch and code along. you can refer the below stuffs. Getting Started with Angular JS :- http://bit.ly/ng-kindle Building SPA with Angular and MVC 5:- http://ow.ly/Jh4bI Demo Site:- http://moviereview.rahulsahay.com/#/ Thanks for Joining Me! Thanks, Rahul Sahay Happy Coding CodeProject

Thanks, Rahul Happy Coding