📄 自测考试管理系统.frm
字号:
VERSION 5.00
Begin VB.Form Form1
BorderStyle = 0 'None
Caption = "Form1"
ClientHeight = 6570
ClientLeft = 0
ClientTop = 0
ClientWidth = 9465
KeyPreview = -1 'True
LinkTopic = "Form1"
Picture = "自测考试管理系统.frx":0000
ScaleHeight = 438
ScaleMode = 0 'User
ScaleWidth = 631
ShowInTaskbar = 0 'False
StartUpPosition = 3 '窗口缺省
Begin VB.Timer Timer1
Left = 840
Top = 3720
End
Begin VB.Label Label1
BackStyle = 0 'Transparent
Caption = "北华航天财会金融系 2005.5.16"
BeginProperty Font
Name = "宋体"
Size = 12
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H00008000&
Height = 375
Index = 5
Left = 1920
TabIndex = 5
Top = 5040
Width = 4935
End
Begin VB.Label Label1
BackStyle = 0 'Transparent
Caption = "正在连接数据库服务器...."
BeginProperty Font
Name = "宋体"
Size = 12
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H00FF0000&
Height = 375
Index = 4
Left = 3120
TabIndex = 4
Top = 3600
Width = 3255
End
Begin VB.Label Label1
BackStyle = 0 'Transparent
Caption = "评阅试卷"
BeginProperty Font
Name = "宋体"
Size = 15
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H00FF0000&
Height = 375
Index = 3
Left = 3120
TabIndex = 3
Top = 3000
Width = 1455
End
Begin VB.Label Label1
BackStyle = 0 'Transparent
Caption = "定制试卷"
BeginProperty Font
Name = "宋体"
Size = 15
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H00FF0000&
Height = 375
Index = 2
Left = 3120
TabIndex = 2
Top = 2400
Width = 1455
End
Begin VB.Label Label1
BackStyle = 0 'Transparent
Caption = "试卷管理"
BeginProperty Font
Name = "宋体"
Size = 15
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H00FF0000&
Height = 375
Index = 1
Left = 3120
TabIndex = 1
Top = 1800
Width = 1455
End
Begin VB.Label Label1
BackColor = &H80000003&
BackStyle = 0 'Transparent
Caption = "欢迎使用会计电算化自测考试系统"
BeginProperty Font
Name = "隶书"
Size = 24
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H00FF00FF&
Height = 615
Index = 0
Left = 960
TabIndex = 0
Top = 600
Width = 8055
End
End
Attribute VB_Name = "Form1"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Form_Click()
Unload Me
systemlogon.Show: systemlogon.SetFocus
End Sub
Private Sub Form_GotFocus()
'On Error GoTo dealerror '测试是否可以连接的SQL Sever服务器
Me.Enabled = False '测试完成之前禁止窗体相应用户操作
'创建于数据库的连接
Dim objcn As New Connection '定义并实例化连接对象
With objcn '建立连接
.Provider = "sqloledb"
.ConnectionString = "use id=sa;pwd=123;data source=(local);" & _
"initial catalog=自测考试"
.Open
.Close
End With
Set objcn = Nothing
Label1(4) = "已连接到数据库服务器"
Timer1.Interval = 3000
Me.Enabled = True
Exit Sub
dealerror:
MsgBox "不能正确连接到数据库,请与系统管理员联系!", vbCritical
Unload Me
End Sub
Private Sub Form_KeyPress(KeyAscii As Integer)
Unload Me
systemlogon.Show: systemlogon.SetFocus
End Sub
Private Sub Label1_Click(Index As Integer)
Unload Me
systemlogon.Show: systemlogon.SetFocus
End Sub
Private Sub Timer1_Timer()
Unload Me
systemlogon.Show: systemlogon.SetFocus
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -