📄 jihuo.frm
字号:
VERSION 5.00
Begin VB.Form jihuo
Caption = "读者卡号激活"
ClientHeight = 2670
ClientLeft = 60
ClientTop = 345
ClientWidth = 4545
Icon = "jihuo.frx":0000
LinkTopic = "Form1"
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 2670
ScaleWidth = 4545
StartUpPosition = 2 '屏幕中心
Begin VB.Data studentdata2
Caption = "Data1"
Connect = "Access"
DatabaseName = "db2.mdb"
DefaultCursorType= 0 '缺省游标
DefaultType = 2 '使用 ODBC
Exclusive = 0 'False
Height = 285
Left = 2880
Options = 0
ReadOnly = 0 'False
RecordsetType = 1 'Dynaset
RecordSource = "student"
Top = 120
Visible = 0 'False
Width = 1215
End
Begin VB.Frame Frame1
Caption = "请输入要激活的"
Height = 2175
Left = 240
TabIndex = 0
Top = 240
Width = 4095
Begin VB.TextBox Text2
Height = 375
IMEMode = 3 'DISABLE
Left = 1440
PasswordChar = "*"
TabIndex = 6
Top = 960
Width = 2175
End
Begin VB.CommandButton Command2
Caption = "取 消"
Height = 375
Left = 2400
TabIndex = 4
Top = 1560
Width = 975
End
Begin VB.CommandButton Command1
Caption = "激 活"
Height = 375
Left = 720
TabIndex = 3
Top = 1560
Width = 975
End
Begin VB.TextBox Text1
Height = 375
Left = 1440
TabIndex = 2
Top = 360
Width = 2175
End
Begin VB.Label Label2
Caption = "密码:"
BeginProperty Font
Name = "宋体"
Size = 14.25
Charset = 134
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 495
Left = 480
TabIndex = 5
Top = 960
Width = 975
End
Begin VB.Label Label1
AutoSize = -1 'True
Caption = "卡号:"
BeginProperty Font
Name = "宋体"
Size = 15
Charset = 134
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 300
Left = 480
TabIndex = 1
Top = 360
Width = 810
End
End
End
Attribute VB_Name = "jihuo"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Command1_Click()
Dim b As Integer
If Text1.Text = "" Then
MsgBox "你还没有输入卡号呢,请输入!"
Else
studentdata2.Recordset.MoveFirst
flag3:
If InStr(studentdata2.Recordset.Fields("卡号"), Text1.Text) And InStr(studentdata2.Recordset.Fields("密码"), Text2.Text) Then
If studentdata2.Recordset.Fields("挂失否") = "是" Then
b = MsgBox("真的要激活吗?", vbOKCancel)
If b = 1 Then
studentdata2.Recordset.Edit
studentdata2.Recordset.Fields("挂失否") = "否"
studentdata2.Recordset.Update
MsgBox "激活成功!"
Unload jihuo
End If
Else
MsgBox "该卡号已经激活"
End If
Else
studentdata2.Recordset.MoveNext
If Not studentdata2.Recordset.EOF Then
GoTo flag3
Else
MsgBox "该卡号存在请重试!"
End If
End If
End If
End Sub
Private Sub Command2_Click()
Unload jihuo
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -