📄 frmffyset.frm
字号:
TabIndex = 20
Top = 1320
Width = 1935
_ExtentX = 3413
_ExtentY = 582
_Version = 393216
Locked = -1 'True
ListField = "名称"
Text = ""
End
Begin VB.TextBox Text5
DataField = "提成率"
DataSource = "Adodc1"
Height = 270
Left = 960
Locked = -1 'True
TabIndex = 19
Top = 2950
Width = 1900
End
Begin VB.TextBox Text4
DataField = "身份证号码"
DataSource = "Adodc1"
Height = 270
Left = 960
Locked = -1 'True
TabIndex = 17
Top = 1804
Width = 1900
End
Begin VB.TextBox Text3
DataField = "年龄"
DataSource = "Adodc1"
Height = 270
Left = 960
Locked = -1 'True
TabIndex = 4
Top = 1022
Width = 1900
End
Begin VB.TextBox Text2
DataField = "姓名"
DataSource = "Adodc1"
Height = 270
Left = 960
Locked = -1 'True
TabIndex = 3
Top = 631
Width = 1900
End
Begin VB.TextBox Text1
DataField = "编号"
DataSource = "Adodc1"
Height = 270
Left = 960
Locked = -1 'True
TabIndex = 2
Top = 240
Width = 1900
End
Begin VB.Label Label8
AutoSize = -1 'True
Caption = "提成率"
Height = 180
Left = 120
TabIndex = 18
Top = 3000
Width = 540
End
Begin VB.Label Label7
AutoSize = -1 'True
Caption = "身份证号"
Height = 180
Left = 120
TabIndex = 16
Top = 1816
Width = 720
End
Begin VB.Label Label5
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "状态"
Height = 180
Left = 120
TabIndex = 10
Top = 2210
Width = 360
End
Begin VB.Label Label4
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "性别"
Height = 180
Left = 120
TabIndex = 9
Top = 1422
Width = 360
End
Begin VB.Label Label3
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "年龄"
Height = 180
Left = 120
TabIndex = 8
Top = 1028
Width = 360
End
Begin VB.Label Label2
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "姓名"
Height = 180
Left = 120
TabIndex = 7
Top = 634
Width = 360
End
Begin VB.Label Label1
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "服务员号"
Height = 180
Left = 120
TabIndex = 6
Top = 240
Width = 720
End
Begin VB.Label Label6
AutoSize = -1 'True
Caption = "工作内容"
Height = 180
Left = 120
TabIndex = 5
Top = 2604
Width = 720
End
End
Begin MSDataGridLib.DataGrid DataGrid1
Bindings = "FrmFFYset.frx":19C1
Height = 4935
Left = 120
TabIndex = 23
Top = 240
Width = 6375
_ExtentX = 11245
_ExtentY = 8705
_Version = 393216
AllowUpdate = -1 'True
HeadLines = 2
RowHeight = 15
BeginProperty HeadFont {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "宋体"
Size = 9
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "宋体"
Size = 9
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ColumnCount = 2
BeginProperty Column00
DataField = ""
Caption = ""
BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED}
Type = 0
Format = ""
HaveTrueFalseNull= 0
FirstDayOfWeek = 0
FirstWeekOfYear = 0
LCID = 2052
SubFormatType = 0
EndProperty
EndProperty
BeginProperty Column01
DataField = ""
Caption = ""
BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED}
Type = 0
Format = ""
HaveTrueFalseNull= 0
FirstDayOfWeek = 0
FirstWeekOfYear = 0
LCID = 2052
SubFormatType = 0
EndProperty
EndProperty
SplitCount = 1
BeginProperty Split0
BeginProperty Column00
EndProperty
BeginProperty Column01
EndProperty
EndProperty
End
End
Attribute VB_Name = "FrmFFYset"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub setLock()
Text1.Locked = False
Text2.Locked = False
Text3.Locked = False
DataCombo1.Locked = False
Text4.Locked = False
DataCombo2.Locked = False
DataCombo3.Locked = False
Text5.Locked = False
End Sub
Private Sub setLocked()
Text1.Locked = True
Text2.Locked = True
Text3.Locked = True
DataCombo1.Locked = True
Text4.Locked = True
DataCombo2.Locked = True
DataCombo3.Locked = True
Text5.Locked = True
End Sub
Private Sub Command1_Click()
Select Case Command1.Caption
Case "添加"
Text1.SetFocus
Command3.Enabled = False
Command4.Enabled = False
Command1.Caption = "取消"
Command2.Enabled = True
Adodc1.Recordset.AddNew
Case "取消"
Adodc1.Recordset.CancelBatch adAffectCurrent
Adodc1.Recordset.MoveFirst
Command1.Caption = "添加"
Command3.Enabled = True
Command4.Enabled = True
Command2.Enabled = False
Command1.Enabled = True
End Select
End Sub
Private Sub Command2_Click()
Adodc1.Recordset.UpdateBatch adAffectCurrent
Command2.Enabled = False
Command1.Enabled = True
Command3.Enabled = True
End Sub
Private Sub Command3_Click()
Adodc1.Recordset.UpdateBatch adAffectCurrent
Call setLock
Command2.Enabled = True
Command1.Enabled = False
Command3.Enabled = False
Text1.SetFocus
End Sub
Private Sub Command4_Click()
Adodc1.Recordset.Delete
End Sub
Private Sub Command5_Click()
If Command1.Caption = "取消" Then Adodc1.Recordset.CancelBatch adAffectCurrent
Unload Me
End Sub
Private Sub Form_Activate()
Call setLocked
End Sub
Private Sub Form_Load()
Adodc1.ConnectionString = conn1
Adodc2.ConnectionString = conn1
Adodc3.ConnectionString = conn1
Adodc4.ConnectionString = conn1
Adodc1.RecordSource = "select * from 服务员"
Adodc1.Refresh
Adodc2.RecordSource = "select * from 类别设置 where 标识='XB'"
Adodc2.Refresh
Adodc3.RecordSource = "select * from 类别设置 where 标识='ZT'"
Adodc3.Refresh
Adodc4.RecordSource = "select * from 类别设置 where 标识='GZNR'"
Adodc4.Refresh
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -