ASP.NET Syntax ASP.NET Syntax for Web Controls
Creates a hidden field that is used to store a non-displayed value.
Declarative Syntax
<asp:HiddenField
EnableTheming = "True | False"
EnableViewState = "True | False"
ID = "string"
OnDataBinding = "DataBinding event handler"
OnDisposed = "Disposed event handler"
OnInit = "Init event handler"
OnLoad = "Load event handler"
OnPreRender = "PreRender event handler"
OnUnload = "Unload event handler"
OnValueChanged = "ValueChanged event handler"
runat = "server"
SkinID = "string"
Value = "string"
Visible = "True | False"
/>
For information on the individual members of this class, see HiddenField in the class library.
The HiddenField control renders as an <input type = "hidden"> element that can store a value that needs to persist across posts to the server.
The following example demonstrates how to use the HiddenField control to store a hidden value on a rendered Web page.
<asp:hiddenfield id="HiddenField1" runat="server" value="1" />
HiddenField Class HiddenField Web Server Control