📄 frmpay.frm
字号:
VERSION 5.00
Begin VB.Form FrmPay
BackColor = &H00FFC0C0&
BorderStyle = 1 'Fixed Single
Caption = "缴纳罚款"
ClientHeight = 1950
ClientLeft = 45
ClientTop = 360
ClientWidth = 3630
LinkTopic = "Form1"
MaxButton = 0 'False
MDIChild = -1 'True
MinButton = 0 'False
ScaleHeight = 1950
ScaleWidth = 3630
Begin VB.TextBox TextPayID
Height = 375
Left = 1320
TabIndex = 3
Top = 960
Width = 2055
End
Begin VB.CommandButton CmdCancel
Cancel = -1 'True
Caption = "取消"
Height = 375
Left = 2280
TabIndex = 1
Top = 1440
Width = 1095
End
Begin VB.CommandButton CmdPay
Caption = "缴纳罚款"
Default = -1 'True
Height = 375
Left = 840
TabIndex = 0
Top = 1440
Width = 1095
End
Begin VB.Label Label2
BackStyle = 0 'Transparent
Caption = "请手动输入或通过读卡器读入缴纳罚款的读者ID:"
BeginProperty Font
Name = "楷体_GB2312"
Size = 12
Charset = 134
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H00FF0000&
Height = 615
Left = 240
TabIndex = 4
Top = 120
Width = 3135
End
Begin VB.Label Label1
BackStyle = 0 'Transparent
Caption = "读者ID:"
BeginProperty Font
Name = "楷体_GB2312"
Size = 12
Charset = 134
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H00FF0000&
Height = 255
Left = 240
TabIndex = 2
Top = 960
Width = 1095
End
End
Attribute VB_Name = "FrmPay"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub CmdCancel_Click() '取消
Unload Me
End Sub
'缴纳罚款
Private Sub CmdPay_Click()
Dim str As String
'检验输入内容
If Len(Trim(Me.TextPayID.Text)) <= 0 Then
MsgBox "请输入读者ID!"
Exit Sub
ElseIf Len(Trim(Me.TextPayID.Text)) > 16 Then
MsgBox "您输入的读者ID过长!"
Exit Sub
End If
'生成要发送的数据 = Pay,Rdr_ID
str = "Pay," & Trim(Me.TextPayID.Text)
'检验sock连接并向服务器发送数据
If MDIFrm.SockToSvr.State <> sckConnected Then
MsgBox "还没有连接数据库,不能发送请求!"
Exit Sub
End If
MDIFrm.SockToSvr.SendData str
Unload Me
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -