Working with State
Our calculator example is dynamic, but stateless, meaning that no information is carried over from one request to the next. This is the default condition for a web application. For simple processing, statelessness isn’t a problem. In our example, a user provides some swimming data, and the results of the calculations are returned. There isn’t any need to carry data from one request to another, because each request is entirely self-contained.
For more complex applications, you generally need access to data that spans multiple requests. This data is called state, and a web application that relies on it is called stateful. ASP.NET provides four forms of state:
- Form input state: In this state, the input fields show the values ...