2017年12月17日 ASP.NET 12个表单元素&&简单控件/复合控件

2022-12-12,,,,

12个表单元素可以分为三大类

第一类:文本类

<input type = "text" />  //普通文本框

<input type = "password" /> //密码文本框

<input type = "hidden" /> //隐藏域

<textrea></textrea> //可变动文本框

第二类:按钮类

<input type = "button" /> //普通按钮

<input type = "reset" /> //重置按钮

//下面这两个可以用来往数据库提交数据
<input type = "submit" /> //提交按钮 <input type = "image"> //图片按钮

第三类:选择类

<input type = "radio" /> //单选按钮

<input type = "checkbox"> //复选按钮

<input type ="file" /> // 选择文件按钮

<select>
<opention></opention> //下拉列表
</select>

简单控件

.Lable // 文字

.Literal  //直接输出文字,不显示HTML的代码

.TextBox  TextMode="MultiLine" //变为多行文本框
TextMode="password" //变为密码框
TextMode="SingleLine" //变为单行文本框 .HiddenFiled //隐藏域 .Button //提交按钮 .ImageButton //图片提交按钮

复合控件

.radio radioButton // 单选按钮
radioButtonList //多行单选按钮 .checkbox checkbox //多选按钮
checkboxList //多行多选按钮 .select option DropDownList //只能选择一个text
ListBox // 可以选择多个text

2017年12月17日 ASP.NET 12个表单元素&&简单控件/复合控件的相关教程结束。

《2017年12月17日 ASP.NET 12个表单元素&&简单控件/复合控件.doc》

下载本文的Word格式文档,以方便收藏与打印。