【文件属性】:
文件名称:VB课设学生成绩管理系统
文件大小:187KB
文件格式:DOC
更新时间:2012-01-16 04:50:13
VB课设
VB课设,保证合格,全套,有代码'数据有效性检查
If txtUser = "" Then
MsgBox "请输入用户名"
txtUser.SetFocus
Exit Sub
End If
If txtPwd = "" Then
MsgBox "请输入密码"
txtPwd.SetFocus
Exit Sub
End If
NameKey = MakeStr(txtUser)
PasswordKey = MakeStr(txtPwd)
'判断用户是否存在
If MyUser.In_DB(NameKey) = False Then
MsgBox "用户名不存在"
Try_times = Try_times + 1
If Try_times >= 3 Then
MsgBox "您已经三次尝试进入本系统,均不成功,系统将关闭"
DBapi_Disconnect
End
Else
Exit Sub
End If
End If
'判断密码是否正确
If MyUser.GetPwd(NameKey) <> PasswordKey Then
MsgBox "密码错误"
Try_times = Try_times + 1
If Try_times >= 3 Then
MsgBox "您已经三次尝试进入本系统,均不成功,系统将关闭"
…
End If
'登录成功,将当前用户的信息保存在CurUser中
CurUser.UserName = MyUser.UserName
'关闭自己
Unload Me
End Sub