📄 frmovertimeinfolist.frm
字号:
VERSION 5.00
Object = "{5E9E78A0-531B-11CF-91F6-C2863C385E30}#1.0#0"; "MSFLXGRD.OCX"
Object = "{0D452EE1-E08F-101A-852E-02608C4D0BB4}#2.0#0"; "FM20.DLL"
Begin VB.Form frmOverTimeInfoList
BorderStyle = 3 'Fixed Dialog
Caption = "其它考勤信息列表"
ClientHeight = 7380
ClientLeft = 150
ClientTop = 150
ClientWidth = 8805
Icon = "frmOverTimeInfoList.frx":0000
LinkTopic = "Form1"
MaxButton = 0 'False
MDIChild = -1 'True
MinButton = 0 'False
ScaleHeight = 7380
ScaleWidth = 8805
ShowInTaskbar = 0 'False
Begin MSFlexGridLib.MSFlexGrid OverTimeGrid1
Height = 5655
Left = 240
TabIndex = 1
Top = 960
Width = 8055
_ExtentX = 14208
_ExtentY = 9975
_Version = 393216
SelectionMode = 1
AllowUserResizing= 1
End
Begin MSForms.CommandButton cmdSearch
Height = 375
Left = 5520
TabIndex = 6
Top = 6840
Width = 975
Caption = "查找"
PicturePosition = 327683
Size = "1720;661"
Picture = "frmOverTimeInfoList.frx":0442
FontName = "宋体"
FontHeight = 180
FontCharSet = 134
FontPitchAndFamily= 34
ParagraphAlign = 3
End
Begin MSForms.CommandButton cmdChange
Height = 375
Left = 4080
TabIndex = 5
Top = 6840
Width = 975
Caption = "修改"
PicturePosition = 327683
Size = "1720;661"
FontName = "宋体"
FontHeight = 180
FontCharSet = 134
FontPitchAndFamily= 34
ParagraphAlign = 3
End
Begin MSForms.CommandButton cmdDel
Height = 375
Left = 2640
TabIndex = 4
Top = 6840
Width = 975
Caption = "删除"
PicturePosition = 327683
Size = "1720;661"
FontName = "宋体"
FontHeight = 180
FontCharSet = 134
FontPitchAndFamily= 34
ParagraphAlign = 3
End
Begin MSForms.CommandButton cmdOk
Height = 375
Left = 1200
TabIndex = 3
Top = 6840
Width = 975
Caption = "添加"
PicturePosition = 327683
Size = "1720;661"
Picture = "frmOverTimeInfoList.frx":34C4
FontName = "宋体"
FontHeight = 180
FontCharSet = 134
FontPitchAndFamily= 34
ParagraphAlign = 3
End
Begin MSForms.CommandButton cmdExit
Height = 375
Left = 6960
TabIndex = 2
Top = 6840
Width = 975
Caption = "返回"
PicturePosition = 327683
Size = "1720;661"
FontName = "宋体"
FontHeight = 180
FontCharSet = 134
FontPitchAndFamily= 34
ParagraphAlign = 3
End
Begin VB.Label Label1
Caption = "员工加班信息列表"
BeginProperty Font
Name = "宋体"
Size = 21.75
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 495
Left = 240
TabIndex = 0
Top = 240
Width = 3615
End
Begin VB.Menu pop_menu2
Caption = "弹出式2"
Visible = 0 'False
Begin VB.Menu addStuffOverTimeInfo
Caption = "添加员工加班信息"
End
Begin VB.Menu checkStuffInOutInfo
Caption = "查询员工加班信息"
End
Begin VB.Menu chgStuffOverTimeInfo
Caption = "修改员工加班信息"
End
Begin VB.Menu delStuffOverTimeInfo
Caption = "删除员工加班信息"
End
Begin VB.Menu refresh
Caption = "刷新"
End
End
End
Attribute VB_Name = "frmOverTimeInfoList"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Public Function showgrid1(ByVal sql As String)
Dim rs As ADODB.Recordset
Dim strMsg As String
Set rs = ExecuteSQL(sql, strMsg)
Call FillData(rs, OverTimeGrid1)
End Function
Private Sub addStuffOverTimeInfo_Click()
frmAddOverTimeInfo.Show
End Sub
Private Sub checkStuffOverTimeInfo_Click()
'frmCheckOverTimeInfo.Show
End Sub
Private Sub checkStuffInOutInfo_Click()
frmCheckKQ3.Show
End Sub
Private Sub chgStuffOverTimeInfo_Click()
frmChgOverTimeInfo.Show
Call OverTimeGrid1_DblClick
End Sub
Private Sub cmdChange_Click()
frmChgOverTimeInfo.Show
End Sub
Private Sub cmdDel_Click()
Call delStuffOverTimeInfo_Click
End Sub
Private Sub cmdExit_Click()
Unload Me
End Sub
Private Sub cmdOk_Click()
frmAddOverTimeInfo.Show
End Sub
Private Sub cmdSearch_Click()
frmCheckKQ3.Show
End Sub
Public Sub delStuffOverTimeInfo_Click()
Dim strOverTime As String
If OverTimeGrid1.Rows <= 1 Then Exit Sub
If OverTimeGrid1.Row < 1 Then Exit Sub
strOverTime = OverTimeGrid1.TextMatrix(OverTimeGrid1.Row, 1)
'MsgBox strOverTime
If MsgBox("你真的要删除该员工的上下班信息吗?", vbQuestion + vbYesNo) = vbYes Then
Dim strSql As String
Dim strMsg As String
Dim rs As New ADODB.Recordset
strSql = "delete * from OverTimeInfo where ID=" & strOverTime
Set rs = ExecuteSQL(strSql, strMsg)
Call Form_Load
End If
End Sub
Private Sub Form_Load()
Dim sql3 As String
Dim strmsg3 As String
Dim rs3 As New ADODB.Recordset
sql3 = "select * from OvertimeInfo"
Set rs3 = ExecuteSQL(sql3, strmsg3)
Call showData(sql3, OverTimeGrid1)
End Sub
Public Sub OverTimeGrid1_DblClick()
frmChgOverTimeInfo.Show
Dim strnow As Date
If OverTimeGrid1.Rows <= 1 Then Exit Sub
If OverTimeGrid1.Row <= 1 Then Exit Sub
frmChgOverTimeInfo.txtID.Text = OverTimeGrid1.TextMatrix(OverTimeGrid1.Row, 2)
frmChgOverTimeInfo.txtName.Text = OverTimeGrid1.TextMatrix(OverTimeGrid1.Row, 3)
frmChgOverTimeInfo.COverDay.Text = OverTimeGrid1.TextMatrix(OverTimeGrid1.Row, 4)
frmChgOverTimeInfo.SOverDays.Text = OverTimeGrid1.TextMatrix(OverTimeGrid1.Row, 5)
strnow = OverTimeGrid1.TextMatrix(OverTimeGrid1.Row, 6)
frmChgOverTimeInfo.dtpET.Value = strnow
frmChgOverTimeInfo.tID.Text = OverTimeGrid1.TextMatrix(OverTimeGrid1.Row, 1)
End Sub
Private Sub OverTimeGrid1_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
If Button = 2 Then
Me.PopupMenu pop_menu2
End If
End Sub
Private Sub refresh_Click()
Call Form_Load
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -