Written by Ananya Chandra on October 19, 2013 in Programming Definitions

What is State Management in ASP.Net?

GET ALERTS:

Get our Latest updates delivered to your mailbox!

State Management is one of the most important concepts in ASP.NET. HTTP is a stateless protocol. And it is called so because as every time you request for a page from the server, it is treated as a new page. Data from one page is not saved on the other page. Hence to overcome this and for easy navigation of information from one page to another page we use state management techniques. State Management techniques are of two kinds and ASP.net gives us a good frame in maintaining the state of pages information on different pages or on same page. The two types are Server side state management and Client side state management. 

state management in asp.net

Client side state management: As the name says client side,  the state information is saved on the client side and this keeps travelling between server and client upon request and response. The downside of using this is, when personal information such as password, username, bank login details are saved on client side and while traveling between server and client anyone can try to retrieve it and this can be misused.

Server side state management: As the name says server side,  the state information is saved on the server side and information stored is secure. But this uses a lot of memory on the server side.

Techniques used under client and server side are:

Client side

Server side

Hidden fields

Application State

Cookies

Session State

Control State

Query String

View State

Easy way of remembering them:

Here Comes Cool Qualities Versus Another Side

Hence as developer we use both client and server side techniques depending upon the requirement and situation. We will be coming-up with in depth analysis of each and every State Management Techniques in ASP.NET. Stay tuned for more information.

{ 4 comments… read them below or add one }

ranadheer October 22, 2013 at 7:04 pm

Nice post. You said, server side State management is secure than client side state management but it uses a lot of memory on the server side. So is it impacts on the page load time ?

Reply

Ananya Chandra October 24, 2013 at 12:46 am

Yes, it does by reducing the bandwidth .By sending state information back and forth to the client side which increases bandwidth requirements and hence it slows on the page load time as it has to store large amounts of information which maybe > 1kb on server side.

Reply

ranadheer October 24, 2013 at 11:58 am

Ohh. Thanks for the info ananya. So which is better to use ? client side state managenent or server side state management ?

Reply

Ananya Chandra December 20, 2013 at 6:49 am

Well, it totally depends on where you want to store your state information. Hence for better scalibility we have to keen in mind the pros and cons of all the state technique.

Reply

Leave a Comment

Previous post:

Next post: