网络应用与开发复习资料docx.docx
《网络应用与开发复习资料docx.docx》由会员分享,可在线阅读,更多相关《网络应用与开发复习资料docx.docx(24页珍藏版)》请在冰豆网上搜索。
网络应用与开发复习资料docx
1_1:
用2个label控件、1个textbox控件、1个button控件制作一个简单网页,实现提交后,页面显示:
欢迎XXX(考生姓名)!
成功就是如此简单,赶快行动吧
各控件的属性名称及属性值
控件类别
控件
屈性名称
属性值
备注
Web控件
Label
Id
Label1
用于显示提示信息
Text
请输入您的姓名
ForeColor
#ooooco
蓝色
Label
Id
Label2
在用户单击“确定”按钮后显示欢迎信息
Text
空
Font.Size
Medium
ForeColor
#ooooco
蓝色
TextBox
Id
TextBoxl
用于输入考生姓名
Text
空
Button
Id
Buttonl
确定按钮
Text
确定
写出按钮事件代码:
(P3)
答案:
Aspx页面代码:
//www.w3.org/1999/xhtml">
无标题页
LabelTD=,/Label1runat二"server"Font-Bold二"True"
Font-Size=,/XX-Largez/ForeColor二"#0000C0〃
Text二"请输入您的姓名/zX/asp:
Label>
TextBoxID二"TcxtBoxl"runat=zzserver,z>
TextBoxXbr/>ButtonID二"Button1"runat二"server"Font-Bold二"True"
Font-Size=,/XX-Large/zText二"确定"/Xbr/>
LabelID二"Label2〃runat二"server"Height二"97px〃Width=//385px//Font-Size二〃Medium"ForeColor^^ftOOOOCO^X/asp:
Label>