📄 frmlinliaomanedit.frm
字号:
VERSION 5.00
Begin VB.Form frmlinliaomanEdit
Caption = "领料人员编辑"
ClientHeight = 4710
ClientLeft = 60
ClientTop = 450
ClientWidth = 6045
LinkTopic = "Form1"
ScaleHeight = 4710
ScaleWidth = 6045
StartUpPosition = 2 '屏幕中心
Begin VB.ComboBox txtzhiwu
Height = 300
ItemData = "frmlinliaomanEdit.frx":0000
Left = 4320
List = "frmlinliaomanEdit.frx":0013
TabIndex = 15
Top = 1680
Width = 1575
End
Begin VB.CommandButton cmdBumen
Caption = "...."
Height = 375
Left = 2760
TabIndex = 9
Top = 1680
Width = 495
End
Begin VB.TextBox txtBeizhu
Height = 855
Left = 1320
TabIndex = 4
Top = 2880
Width = 4575
End
Begin VB.TextBox txtname
Height = 375
Left = 4320
TabIndex = 3
Top = 1080
Width = 1575
End
Begin VB.TextBox txtphone
Height = 375
Left = 1320
TabIndex = 2
Top = 2280
Width = 1335
End
Begin VB.TextBox txtBumen
Height = 375
Left = 1320
TabIndex = 1
Top = 1680
Width = 1335
End
Begin VB.TextBox txtId
Height = 375
Left = 1320
TabIndex = 0
Top = 1080
Width = 1335
End
Begin VB.Image imgOk
Height = 480
Left = 1800
Picture = "frmlinliaomanEdit.frx":003B
Top = 3840
Width = 480
End
Begin VB.Label lblok
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "确定"
Height = 180
Left = 1800
TabIndex = 14
Top = 4440
Width = 360
End
Begin VB.Label lblExit
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "退出"
Height = 180
Left = 3480
TabIndex = 13
Top = 4440
Width = 360
End
Begin VB.Image imgExit
Height = 480
Left = 3360
Picture = "frmlinliaomanEdit.frx":047D
Top = 3960
Width = 480
End
Begin VB.Label Label7
Alignment = 1 'Right Justify
BackStyle = 0 'Transparent
Caption = "备注"
BeginProperty Font
Name = "隶书"
Size = 14.25
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 375
Left = 120
TabIndex = 12
Top = 2880
Width = 1095
End
Begin VB.Label Label6
Alignment = 1 'Right Justify
BackStyle = 0 'Transparent
Caption = "联糸电话"
BeginProperty Font
Name = "隶书"
Size = 14.25
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 375
Left = 0
TabIndex = 11
Top = 2280
Width = 1215
End
Begin VB.Label Label5
Alignment = 1 'Right Justify
BackStyle = 0 'Transparent
Caption = "职务"
BeginProperty Font
Name = "隶书"
Size = 14.25
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 375
Left = 3360
TabIndex = 10
Top = 1680
Width = 855
End
Begin VB.Label Label4
Alignment = 1 'Right Justify
BackStyle = 0 'Transparent
Caption = "部门"
BeginProperty Font
Name = "隶书"
Size = 14.25
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 375
Left = 120
TabIndex = 8
Top = 1680
Width = 1095
End
Begin VB.Label Label3
Alignment = 1 'Right Justify
BackStyle = 0 'Transparent
Caption = "员工姓名"
BeginProperty Font
Name = "隶书"
Size = 14.25
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 375
Left = 3000
TabIndex = 7
Top = 1080
Width = 1215
End
Begin VB.Label Label2
Alignment = 1 'Right Justify
BackStyle = 0 'Transparent
Caption = "员工工号"
BeginProperty Font
Name = "隶书"
Size = 14.25
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 375
Left = 0
TabIndex = 6
Top = 1080
Width = 1215
End
Begin VB.Label Label1
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "领料人员编辑"
BeginProperty Font
Name = "隶书"
Size = 18
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 360
Left = 1800
TabIndex = 5
Top = 240
Width = 2160
End
End
Attribute VB_Name = "frmlinliaomanEdit"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Public oriid As String
Public modify As Boolean
Private Sub Command1_Click()
End Sub
Private Sub cmdBumen_Click()
frmlinliaobumen.Show 1
End Sub
Private Sub Form_Load()
frmlinliaomanEdit.BackColor = RGB(39, 160, 237)
End Sub
Private Function check() As Boolean
If Trim(txtId) = "" Then
MsgBox "员工ID不能为空"
txtId.SetFocus
check = False
Exit Function
End If
If Trim(txtname) = "" Then
MsgBox "员工姓名不能为空"
txtname.SetFocus
check = False
Exit Function
End If
If Trim(txtBumen) = "" Then
MsgBox "所属部门不能为空"
txtBumen.SetFocus
check = False
Exit Function
End If
If Trim(txtzhiwu) = "" Then
MsgBox "所任职务不能为空"
txtzhiwu.SetFocus
check = False
End If
check = True
End Function
Private Sub imgExit_Click()
Unload Me
frmlinliaoman.Show
End Sub
Private Sub imgOk_Click()
If check = False Then
Exit Sub
End If
With mylinliaoman
.YgId = txtId.Text
.YgName = txtname.Text
.bumen = txtBumen.Text
.Zhiwu = txtzhiwu.Text
.Beizhu = txtBeizhu.Text
If modify = False Then
If .in_db(txtId) = True Then
MsgBox "此员工ID已存在,请查正再输入"
txtId.SetFocus
txtId.SelStart = 0
txtId.SelLength = Len(txtId)
Exit Sub
Else
.insert
MsgBox "添加成功"
End If
Else
.update (oriid)
MsgBox "修改成功"
End If
End With
Unload Me
frmlinliaoman.Show
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -