📄 frmgz.frm
字号:
VERSION 5.00
Begin VB.Form frmgz
BackColor = &H00C0FFFF&
BorderStyle = 0 'None
ClientHeight = 2220
ClientLeft = 0
ClientTop = 0
ClientWidth = 5745
LinkTopic = "Form1"
ScaleHeight = 2220
ScaleWidth = 5745
ShowInTaskbar = 0 'False
StartUpPosition = 2 '屏幕中心
Begin VB.Frame Frame1
BackColor = &H00A56E3A&
Height = 2055
Left = 60
TabIndex = 0
Top = 60
Width = 5595
Begin VB.CommandButton cmdExit_GZ
Appearance = 0 'Flat
BeginProperty Font
Name = "MS Serif"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 450
Left = 4035
Picture = "frmgz.frx":0000
Style = 1 'Graphical
TabIndex = 10
Top = 1455
Width = 1455
End
Begin VB.CommandButton CmdEnt_DZ
Appearance = 0 'Flat
BeginProperty Font
Name = "MS Serif"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 450
Left = 2520
Picture = "frmgz.frx":07DA
Style = 1 'Graphical
TabIndex = 9
Top = 1455
Width = 1455
End
Begin VB.TextBox TxtPwd_gz
Appearance = 0 'Flat
BackColor = &H00C0FFFF&
BeginProperty Font
Name = "MS Sans Serif"
Size = 9.75
Charset = 0
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 285
IMEMode = 3 'DISABLE
Left = 3990
PasswordChar = "*"
TabIndex = 4
Text = "Text1"
Top = 600
Width = 1485
End
Begin VB.TextBox TxtPzgzr_gz
Appearance = 0 'Flat
BackColor = &H00C0FFFF&
Height = 285
Left = 1380
TabIndex = 3
Text = "Text1"
Top = 600
Width = 1455
End
Begin VB.TextBox TxtKin_gz
Appearance = 0 'Flat
BackColor = &H00C0FFFF&
Height = 285
Left = 1380
TabIndex = 2
Text = "Text1"
Top = 1020
Width = 1455
End
Begin VB.ComboBox CboGzdwmc
Height = 315
ItemData = "frmgz.frx":0FA1
Left = 1380
List = "frmgz.frx":0FAB
Style = 2 'Dropdown List
TabIndex = 1
Top = 180
Width = 1455
End
Begin VB.Label Label14
Alignment = 2 'Center
BackStyle = 0 'Transparent
Caption = "批准挂帐人"
Height = 225
Index = 0
Left = 120
TabIndex = 8
Top = 660
Width = 1185
End
Begin VB.Label Label7
Alignment = 2 'Center
BackStyle = 0 'Transparent
Caption = "挂帐单位名称"
Height = 225
Index = 0
Left = 120
TabIndex = 7
Top = 240
Width = 1215
End
Begin VB.Label Label6
Alignment = 2 'Center
BackStyle = 0 'Transparent
Caption = "密 码"
Height = 225
Index = 0
Left = 2940
TabIndex = 6
Top = 660
Width = 1005
End
Begin VB.Label Label14
Alignment = 2 'Center
BackStyle = 0 'Transparent
Caption = "挂 帐 金 额"
Height = 225
Index = 1
Left = 120
TabIndex = 5
Top = 1080
Width = 1065
End
Begin VB.Shape Shape2
FillColor = &H00C0FFFF&
FillStyle = 0 'Solid
Height = 285
Index = 0
Left = 60
Top = 180
Width = 1275
End
Begin VB.Shape Shape4
FillColor = &H00C0FFFF&
FillStyle = 0 'Solid
Height = 285
Index = 0
Left = 60
Top = 600
Width = 1275
End
Begin VB.Shape Shape4
FillColor = &H00C0FFFF&
FillStyle = 0 'Solid
Height = 285
Index = 1
Left = 60
Top = 1020
Width = 1275
End
Begin VB.Shape Shape3
FillColor = &H00C0FFFF&
FillStyle = 0 'Solid
Height = 285
Index = 0
Left = 2940
Top = 600
Width = 975
End
End
End
Attribute VB_Name = "frmgz"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Private m_pzgzr As String
Private m_kin As Double
Private m_gzdwmc As String
Private m_result As Boolean
Public Property Get pzgzr() As String '批准挂帐人
pzgzr = m_pzgzr
End Property
Public Property Get kin() As Double '批准金额
kin = m_kin
End Property
Public Property Let kin(VL As Double) '批准金额
m_kin = VL
End Property
Public Property Get gzdwmc() As String '挂帐单位名称
gzdwmc = m_gzdwmc
End Property
Public Property Get result() As Boolean '
result = m_result
End Property
Public Property Let result(VL As Boolean) '
m_result = VL
End Property
Private Sub CmdEnt_DZ_Click()
If chkUser = False Then
MsgBox "用户没有权限操作此项!请联系系统管理员!", vbOKOnly, "信息提示"
Exit Sub
End If
If Val(noComma(TxtKin_gz)) <= 0 Then
MsgBox "挂帐金额必须大于0!", vbInformation, "信息提示"
Exit Sub
End If
m_result = True
m_pzgzr = Trim(TxtPzgzr_gz)
m_kin = Val(noComma(TxtKin_gz))
m_gzdwmc = Trim(CboGzdwmc.Text)
temp_dwmc = Trim(CboGzdwmc.Text)
Unload Me
frmqtyy.printGZD
End Sub
Private Sub cmdExit_GZ_Click()
m_result = False
Unload Me
End Sub
Private Sub Form_Activate()
Call initFrm
End Sub
Private Sub initFrm()
On Error Resume Next
Dim wksql As String
Dim rs As ADODB.Recordset
Dim l As Long
CboGzdwmc.Clear
wksql = "SELECT xm FROM JZdw"
Set rs = GetRsBySQL(wksql)
If rs.RecordCount <= 0 Then
MsgBox "还没有挂帐单位,请先在挂帐管理中设置!", vbInformation, "信息提示"
Call cmdExit_GZ_Click
End If
For l = 0 To rs.RecordCount - 1
CboGzdwmc.AddItem rs!Xm
rs.MoveNext
Next
CboGzdwmc.ListIndex = 0
TxtPzgzr_gz = ""
TxtPwd_gz = ""
TxtKin_gz = Format(m_kin, kfmtc)
CboGzdwmc.SetFocus
End Sub
Private Function chkUser() As Boolean
' Dim wksql As String
' Dim rs As New ADODB.Recordset
On Error GoTo errProc
' chkUser = False
' wksql = "SELECT 1 FROM employees "
' wksql = wksql & " WHERE employee_id='" & Trim(TxtPzgzr_gz) & "'"
' wksql = wksql & " AND pwd='" & Trim(TxtPwd_gz) & "'"
' Set rs = GetRsBySQL(wksql)
' If rs.RecordCount <= 0 Then Exit Function
' chkUser = True
chkUser = GetqtRight(Trim(TxtPzgzr_gz), Trim(TxtPwd_gz), 2)
Exit Function
errProc:
End Function
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -