Monday, 30 November 2015

Difference in AngularJS $rootScope and $scope;

Angularjs share the object which will work like a mediator between the View and Controller. AnjularJs share the two scope which will help to make the glue between View and controller as $scope and $rootscope.

$Scope : It is an object in AngularJs and 
use for communicating between
 the view and controller.
We can find the ng-model
 properties in particular 
controller from the particular
 page by using $scope.

Friday, 27 November 2015

What is View Model in MVC.

View Model work as a hidden layer in MVC applications. It’s a simple class that represents data displaying on the view.

If you will look into MVC, view model is not in the picture. Like;

Model: Used to maintain the business data.
Controller: Maintaining the interaction related details to View.
View: Contains the User Interface.

So, Where is the View model?

When someone first time ask me what is View Model in MVC? I told there is No View Model in MVC.

Friday, 13 November 2015

difference between web api and wcf

We are always little bit confusion when we are making service based application. that which we need to refer Web apt or WCF. The below difference of Web API and WCF will really help to select.

Web API Rest full
ASP.Net WCF Rest Support
Support Protocol
It support only HTTP protocol.
It support multiple protocol such as HTTP, UDP, TCP.
Support WS* Standard
It’s not supporting Transaction or reliable messaging.

It support WS* standard like Transaction, Reliable Messaging. Message security etc.
SOAP Support
WCF was primarily designed for SOAP-based XML messages,
Ship with .Net framework  but available as open source.
Ship with .Net Framework.
Configuration and Attribute
No need of much configuration to use it.
There is hell lot of configuration required to use it and overuse of attributes.
Message Exchange Pattern
It support Request/response only.
It support One Way, Request-Reply, Duplex message Exchange pattern.

Tuesday, 10 November 2015

Angularjs with MVC login form tutorial

Basically for any application we need a login page.  Now demonstrating angularjs with MVC login form tutorial.  Please see the step by step procedure to create the login form like below;

Step 1: Create MVC application in;