+ 3

What is difference between View state and Session state?

27th Nov 2016, 1:42 PM
Akshat Aman
Akshat Aman - avatar
2 Respuestas
+ 3
view state - When another page is loaded, the previous page data is no longer available. It is client side state mechanism. session state - This data available until user closes the browser or session time-outs.It is server side state mechanism. hope this helps.
28th Nov 2016, 5:07 AM
Rishabh Agrawal
Rishabh Agrawal - avatar
0
The view state is valid for the currently shown page and any kind of data will be lost if the user navigates away from the page/view. The session state stores the data for the whole browser session of that user. So even if the user navigates through your website within a valid session, the data will not be lost. A session might be invalidated after some specific circumstances have been met like time out or specific user actions (eg. logout, browser closed etc).
28th Nov 2016, 5:07 AM
Kerem Adıgüzel
Kerem Adıgüzel - avatar