Friday, August 19, 2016

Hidden fields

Store value in an HTML without display it in the user's browser. E.g. Store EmployeeID
ViewState and HiddenField data will lost when navigate away from the page, does not any clean up task.
  • Store as String
  • able to Get or Set the value
  • Maintain across postback
  • accessible to client-side scripts (javascript)
Disadvantage :
  • Hidden field data can be seen in page source.
Difference ViewState and HiddenField is :
Viewstate has 64 based encoding

No comments:

Post a Comment