View State Best Dot Net Training being hidden element in form tag rendered

View State Best Dot Net Training being hidden element in form tag rendered


  1. It’s of type StateBag and is used for storing state/data to be used in postback to the same web form.

  2. ViewState being hidden element in form tag rendered, its different for different clients & is submitted to the server only if the form is submitted or posted.

  3. ViewState is a collection of Key-Value pairs, where Key is of type String and Value is of type Object. But only those objects which are marked as Serializable can be stored in ViewState.

  4. ViewState cannot be programmed on the client in javascript because the value of it is encrypted before it is rendered to the browser.

  5. If ViewState of the page is disabled (<%@Page EnableViewState=”False”) than anything

    added to it is not retained.

  6. Example:1

    And the Code Behind:


    And the Code Behind:

Mr Sandeep Soni, CEO & Founder of Deccansoft Software Services. He has over 21years of Experience in Teaching and Development using Microsoft Technologies. Since 1997, of the total 100000+ students, Deccansoft has trained, he has personally trained over 60,000+ students and we are proud of him because almost every student he had trained is very happy with the quality and many are well placed in various I.T Firms. This will reflect in testimonials on our website.

Please follow and like us:

Leave a Reply

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