Easy Tutorial
❮ Prop Webcontrol Textbox Autopostback Prop Webcontrol Calendar Selecteddates ❯

ASP.NET HtmlForm Control



Definition and Usage

The HtmlForm control is used to control the <form> element. In HTML, the <form> element is used to create a form.

Note: All HTML server controls must be inside the HtmlForm control!

Note: You can only use one HtmlForm control on a page!


Attributes

Attribute Description
Action URL that defines where the data is sent when the form is submitted. Note: This attribute is always set to the URL of the page itself!
Attributes Returns all attribute name and value pairs of the element.
Disabled Boolean value indicating whether the control is disabled. Default is false.
EncType MIME type used to encode the form content.
id Unique ID of the control.
InnerHtml Sets or returns the content between the start and end tags of the HTML element. Special characters are not automatically converted to HTML entities.
InnerText Sets or returns all text between the start and end tags of the HTML element. Special characters are automatically converted to HTML entities.
Method The method the form uses to send data to the server. Legal values are: "post" and "get". Default is "post".
Name The name of the form.
runat Specifies that the control is a server control. Must be set to "server".
Style Sets or returns the CSS properties applied to the control.
TagName Returns the tag name of the element.
Target The target window where the URL is loaded.
Visible Boolean value indicating whether the control is visible.

Example

HTMLForm


❮ Prop Webcontrol Textbox Autopostback Prop Webcontrol Calendar Selecteddates ❯