Viewstate vs Session
Currently i am working on Web Application for which i had to perform some research on storing values in web application Which one is best to be used, As we all known HTTP Protocol is State less. Page can't hold variable [Value] on post back. So let see the working and difference Viewstate vs Session ViewState and Session are used to stored value Syntax : Viewstate (“ VariableName ”) = “ Value ” : Session (“ VariableName ”) = “ Value ” 1. ViewState are only accessible to page. i.e. Page1.aspx has Viewstate("Var1") Same will not be accessible in Page2.aspx. Instead once you call Viewstate("Var1") in page2.aspx it will create new Viewstate ...