frmlogin.frm
来自「这是一个可以用于毕业设计的计算机等级考试模拟系统。管理员能够从题库中抽题来完成命」· FRM 代码 · 共 132 行
FRM
132 行
VERSION 5.00
Begin VB.Form frmAdminLogin
AutoRedraw = -1 'True
BackColor = &H000000FF&
BorderStyle = 0 'None
Caption = "人员登录"
ClientHeight = 2100
ClientLeft = 2790
ClientTop = 3045
ClientWidth = 5175
ControlBox = 0 'False
LinkTopic = "Form1"
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 1240.749
ScaleMode = 0 'User
ScaleWidth = 4859.045
ShowInTaskbar = 0 'False
StartUpPosition = 2 '屏幕中心
Begin VB.CommandButton cmdCancel
Cancel = -1 'True
Caption = "取消"
Height = 390
Left = 3840
TabIndex = 6
Top = 960
Width = 1140
End
Begin VB.CommandButton cmdOK
Caption = "确定"
Default = -1 'True
Height = 390
Left = 3840
TabIndex = 5
Top = 360
Width = 1140
End
Begin VB.Frame FrameLog
Height = 1815
Left = 240
TabIndex = 0
Top = 120
Width = 3375
Begin VB.TextBox txtPassword
Height = 285
IMEMode = 3 'DISABLE
Left = 1200
PasswordChar = "*"
TabIndex = 4
Top = 1080
Width = 1725
End
Begin VB.TextBox txtUserName
Height = 285
Left = 1200
TabIndex = 3
Top = 360
Width = 1725
End
Begin VB.Label lblLabels
Caption = "口令"
BeginProperty Font
Name = "MS Sans Serif"
Size = 12
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 270
Index = 1
Left = 360
TabIndex = 2
Top = 1080
Width = 720
End
Begin VB.Label lblLabels
Caption = "姓名"
BeginProperty Font
Name = "MS Sans Serif"
Size = 12
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 270
Index = 0
Left = 360
TabIndex = 1
Top = 360
Width = 840
End
End
End
Attribute VB_Name = "frmAdminLogin"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Private Sub CmdCancel_Click()
Unload Me
End Sub
Private Sub CmdOK_Click()
If txtUserName.Text = "" Then
MsgBox "请输入姓名", vbCritical, "登录失败"
txtUserName.SetFocus
Exit Sub
End If
If TxtPassword.Text = "" Then
MsgBox "请输入口令", vbCritical, "登录失败"
TxtPassword.SetFocus
Exit Sub
End If
TestUser.Log txtUserName, TxtPassword, administrator
If Not TestUser.LogFail Then
Unload Me
Else
MsgBox "无法登录, 请重试!", vbCritical, "用户登录"
txtUserName.SetFocus
SendKeys "{Home}+{End}"
End If
End Sub
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?