用户注册页面.docx

上传人:b****5 文档编号:3349501 上传时间:2022-11-22 格式:DOCX 页数:8 大小:85.01KB
下载 相关 举报
用户注册页面.docx_第1页
第1页 / 共8页
用户注册页面.docx_第2页
第2页 / 共8页
用户注册页面.docx_第3页
第3页 / 共8页
用户注册页面.docx_第4页
第4页 / 共8页
用户注册页面.docx_第5页
第5页 / 共8页
点击查看更多>>
下载资源
资源描述

用户注册页面.docx

《用户注册页面.docx》由会员分享,可在线阅读,更多相关《用户注册页面.docx(8页珍藏版)》请在冰豆网上搜索。

用户注册页面.docx

用户注册页面

 

ASP程序设计实验报告

 

实验题目:

制作一个用户注册页面

专业班级:

计科系**

姓名:

***

学号:

***

2013年4月12日

实验报告

实验类型__验证_实验室_软件实验室一__

一、实验题目

制作一个用户注册页面

二、实验目的和要求

熟悉并掌握VB脚本语言,包括数据类型,函数,过程,重点掌握VBscript对象和事件。

三、实验内容

制作一个用户注册页面。

四、实验代码

按顺序输入注册信息

SubWindows_Onload

Form1.xm.Focus

EndSub

Subxm_OnkeyPress

IfWindow.Event.Keycode=13Then

Form1.mm.Focus

EndIf

EndSub

Submm_OnkeyPress

IfWindow.Event.Keycode=13Then

Form1.qrmm.Focus

EndIf

EndSub

Subqrmm_OnkeyPress

IfWindow.Event.Keycode=13Then

Form1.nl.Focus

EndIf

EndSub

Subnl_OnkeyPress

IfWindow.Event.Keycode=13Then

Form1.dh.Focus

EndIf

EndSub

Subdh_OnkeyPress

IfWindow.Event.Keycode=13Then

Form1.zz.Focus

EndIf

EndSub

Subzz_OnkeyPress

IfWindow.Event.Keycode=13Then

Form1.email.Focus

EndIf

EndSub

Subemail_OnkeyPress

IfWindow.Event.Keycode=13Then

Form1.button1.Focus

EndIf

EndSub

Subbutton1_OnClick

Dimtxt1,txt2,txt3,txt4,txt5,txt6,txt7,alltxt

txt1=Form1.xm.value

txt2=Form1.nl.value

txt3=Form1.dh.value

txt4=Form1.zz.value

txt5=Form1.mm.value

txt6=Form1.qrmm.value

txt7=Form1.email.value

Iftxt1=""Then

MsgBox"姓名不能为空!

"

Form1.xm.Focus

ExitSub

EndIf

Iftxt5=""Then

MsgBox"密码不能为空!

"

Form1.mm.Focus

ExitSub

EndIf

IfLen(txt5)<6orLen(txt5)>12Then

MsgBox"密码应该在6到12位之间."

Form1.mm.Focus

ExitSub

EndIf

Iftxt6=""Then

MsgBox"确认密码不能为空!

"

Form1.qrmm.Focus

ExitSub

EndIf

Iftxt5<>txt6Then

MsgBox"密码和确认密码不同!

"

Form1.qrmm.Focus

ExitSub

EndIf

Iftxt3=""Then

MsgBox"电话不能为空!

"

Form1.dh.Focus

ExitSub

EndIf

IfnotisNumeric(txt2)Then

MsgBox"请输入数字!

"

Form1.mm.Focus

ExitSub

EndIf

If(InStr("@",txt7)=0andInStr(".",txt7)=0)Then

MsgBox"请输入有效的E-mail地址!

"

Form1.email.Focus

ExitSub

EndIf

alltxt="姓名为:

"+txt1+VbCrlf

alltxt=alltxt+"密码为:

"+txt5+VbCrlf

alltxt=alltxt+"年龄为:

"+txt2+VbCrlf

alltxt=alltxt+"电话为:

"+txt3+VbCrlf

alltxt=alltxt+"住址为:

"+txt4

Intb=MsgBox(alltxt,4+32,"确认提交")

ifIntb=6then

form1.submit

endIf

endsub

subbutton1_onkeypress

ifwindow.event.keycode=13then

button1_onclik

endif

endsub

-->

姓名:


密码:

确认密码:


年龄:

电话:


住址:

email:


五、实验结果

六、实验总结

通过本次实验,我初步掌握了VB脚本语言的使用,学

会了对Vbscript对象和事件的简单应用,虽然在实验中出现了许多问题,但是最终还是解决了,这次实验还是收获了好多,以后会继续努力的。

展开阅读全文
相关资源
猜你喜欢
相关搜索

当前位置:首页 > 小学教育 > 学科竞赛

copyright@ 2008-2022 冰豆网网站版权所有

经营许可证编号:鄂ICP备2022015515号-1