ASP.NET Web Forms - Web server controls
This section introduces Web server control for ASP.NET.Web server controls are special ASP.NET tags that the server understands.
Web server control
Just like HTML server controls, Web server controls are created on the server, and they also require the runat="server" attribute to take effect. However, Web server controls do not necessarily map any existing HTML elements; they can represent more complex elements.
The syntax for creating a Web server control is:
<asp:control_name id="some_id" runat="server" />
Web server control | describe |
---|---|
AdRotator | display a graphic sequence |
Button | Show push button |
Calendar | show calendar |
CalendarDay | day in calendar control |
CheckBox | Show checkbox |
CheckBoxList | Create a multi-select checkbox group |
DataGrid | Display the fields of the data source in the grid |
DataList | Display items from a data source by using templates |
DropDownList | Create drop-down list |
HyperLink | Create hyperlink |
Image | display image |
ImageButton | Show clickable images |
Label | Display programmable static content (allows you to apply styles to its content) |
LinkButton | Create a hyperlink button |
ListBox | Create a single or multiple-select drop-down list |
ListItem | Create an item in a list |
Literal | Display programmable static content (does not enable you to apply styles to its content) |
Panel | Provide containers for other controls |
PlaceHolder | Reserve space for controls added by code |
RadioButton | Create radio buttons |
RadioButtonList | Create a radio button group |
BulletedList | Create a bulleted list |
Repeater | Displays a repeating list of items bound to a control |
Style | Set the style of the control |
Table | Create table |
TableCell | Create table cells |
TableRow | Create table rows |
TextBox | Create text box |
Xml | Display the results of an XML file or XSL transformation |
The table above provides useful Web server controls. Click the corresponding link to get more detailed usage information.