Home >> ASP.NET >> State Management in ASP.NET

State Management in ASP.NET

Hi Everybody,

I am once back with a blog/article/tutorial whatever you think/call it.

State Management in ASP.NET :

HTTP Protocol is State less protocol. In Simple Language, Each and Every time We send a request to server, this is New to server.

To Understand this ,Suppose you took One Textbox and Two Buttons like in Image below:

Now, the task is To Enter Number in Textbox and Click in First Button to Convert to Integer format and then Click Second button to Print Square of Converted Integer in Textbox. What will you do. Lets look at code what I did here.

Now what would I get Result on Second Button Click event. Textbox Result will be 0 even I have entered any number. Don’t agree, try this at home.

This is Because, at the time of Button2 Click new request is send to server and Initial Value of X is picked from server which is 0.

To Prevent the Loose of Data each time we send request to server, ASP.NET have implemented concept of State Management.

State Management is divided into 2 parts according to Functionality.

1) User Based State Management in ASP.NET

  • Cookies
  • QueryStrings
  • ViewState
  • Controls
  • Hidden Fields

2) Server Based State Management in ASP.NET

  • Session
  • Application
  • Profile

I am going to Describe all these States step by step in Different Posts.

All the Series has been posted on DotNetSpider at below Link Resources > Keep Reading.

About John Bhatt

Aka, Prithvi Raj Bhatt, A Proud Nepali, Blogger, Software Developer, ASP.NET, Web Designer & Developer, Faculty and a Troubleshooter blog @PRsBlog

Check Also

Prisma App in Android

Download Prisma on Android from Google Play

Since last month, a photo editing app released 11 June 2016 for iOS created lots of hype. The …

Leave a Reply

Your email address will not be published. Required fields are marked *