⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 frminoutinfolist.frm

📁 企业人事管理系统,有考勤,人员管理等功能,值得研究,也是我付费弄来的,绝对超值
💻 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 frmInOutInfoList 
   BorderStyle     =   3  'Fixed Dialog
   Caption         =   "员工考勤信息"
   ClientHeight    =   7365
   ClientLeft      =   150
   ClientTop       =   435
   ClientWidth     =   8685
   Icon            =   "frmInOutInfoList.frx":0000
   LinkTopic       =   "Form1"
   MaxButton       =   0   'False
   MDIChild        =   -1  'True
   MinButton       =   0   'False
   ScaleHeight     =   7365
   ScaleWidth      =   8685
   ShowInTaskbar   =   0   'False
   Begin MSFlexGridLib.MSFlexGrid KQGrid1 
      Height          =   5535
      Left            =   240
      TabIndex        =   1
      Top             =   1080
      Width           =   7935
      _ExtentX        =   13996
      _ExtentY        =   9763
      _Version        =   393216
      SelectionMode   =   1
      AllowUserResizing=   1
   End
   Begin MSForms.CommandButton cmdSearch 
      Height          =   375
      Left            =   5280
      TabIndex        =   6
      Top             =   6840
      Width           =   975
      Caption         =   "查找"
      PicturePosition =   327683
      Size            =   "1720;661"
      Picture         =   "frmInOutInfoList.frx":0442
      FontName        =   "宋体"
      FontHeight      =   180
      FontCharSet     =   134
      FontPitchAndFamily=   34
      ParagraphAlign  =   3
   End
   Begin MSForms.CommandButton cmdChange 
      Height          =   375
      Left            =   3840
      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            =   2400
      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            =   960
      TabIndex        =   3
      Top             =   6840
      Width           =   975
      Caption         =   "添加"
      PicturePosition =   327683
      Size            =   "1720;661"
      Picture         =   "frmInOutInfoList.frx":34C4
      FontName        =   "宋体"
      FontHeight      =   180
      FontCharSet     =   134
      FontPitchAndFamily=   34
      ParagraphAlign  =   3
   End
   Begin MSForms.CommandButton cmdExit 
      Height          =   375
      Left            =   6720
      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           =   4215
   End
   Begin VB.Menu pop_mnu 
      Caption         =   "弹出式"
      Begin VB.Menu pop_addInOutInfo 
         Caption         =   "添加上下班信息"
      End
      Begin VB.Menu checkInOutInfo 
         Caption         =   "查询上下班信息"
      End
      Begin VB.Menu chgInOutInfo 
         Caption         =   "修改上下班信息"
      End
      Begin VB.Menu pop_DelInOutInfo 
         Caption         =   "删除上下班信息"
      End
      Begin VB.Menu refresh 
         Caption         =   "刷新"
      End
   End
End
Attribute VB_Name = "frmInOutInfoList"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub checkInOutInfo_Click()
  frmCheckKQ1.Show
End Sub

Private Sub chgInOutInfo_Click()
   frmChgInOutInfo.Show
End Sub

Private Sub cmdChange_Click()
  frmChgInOutInfo.Show
End Sub

Private Sub cmdDel_Click()
  Call pop_DelInOutInfo_Click
End Sub

Private Sub cmdExit_Click()
Unload Me
End Sub





Private Sub cmdOk_Click()
   frmAddInOutInfo.Show
End Sub

Private Sub cmdSearch_Click()
  frmCheckKQ1.Show
End Sub

Public Sub Form_Load()
  Dim sql As String
  Dim strMsg As String
  Dim rs As New ADODB.Recordset
  sql = "select * from AttendanceInfo"
  Set rs = ExecuteSQL(sql, strMsg)
  Call showData(sql, KQGrid1)
 
End Sub

Private Sub KQGrid1_DblClick()
     frmChgInOutInfo.Show
       
  
     If KQGrid1.Rows <= 1 Then Exit Sub
     If KQGrid1.Row < 1 Then Exit Sub
     Dim strnow As Date
     Dim strInTime As Date
     Dim strOutTime As Date
     frmChgInOutInfo.txtID.Text = KQGrid1.TextMatrix(KQGrid1.Row, 2)
     frmChgInOutInfo.txtName.Text = KQGrid1.TextMatrix(KQGrid1.Row, 3)
     strnow = KQGrid1.TextMatrix(KQGrid1.Row, 4)
     frmChgInOutInfo.DTPicker2.Value = strnow
     
      If KQGrid1.TextMatrix(KQGrid1.Row, 6) <> "" Then
     
             h = Hour(KQGrid1.TextMatrix(KQGrid1.Row, 6))
             s = Second(KQGrid1.TextMatrix(KQGrid1.Row, 6))
             m = Minute(KQGrid1.TextMatrix(KQGrid1.Row, 6))
             KQGrid1.TextMatrix(KQGrid1.Row, 6) = CDate(h & ":" & m & ":" & s)
             frmChgInOutInfo.dtpBT.Value = KQGrid1.TextMatrix(KQGrid1.Row, 6)
      End If
     
     
      If KQGrid1.TextMatrix(KQGrid1.Row, 7) <> "" Then
     
              h1 = Hour(KQGrid1.TextMatrix(KQGrid1.Row, 7))
              s1 = Second(KQGrid1.TextMatrix(KQGrid1.Row, 7))
              m1 = Minute(KQGrid1.TextMatrix(KQGrid1.Row, 7))
              KQGrid1.TextMatrix(KQGrid1.Row, 6) = CDate(h1 & ":" & m1 & ":" & s1)
     
             frmChgInOutInfo.DTPicker1.Value = KQGrid1.TextMatrix(KQGrid1.Row, 7)
     
      End If
     frmChgInOutInfo.tID.Text = KQGrid1.TextMatrix(KQGrid1.Row, 1)
 End Sub

Public Function showgrid1(ByVal sql As String)
 Dim rs As ADODB.Recordset
 Dim strMsg As String
 Set rs = ExecuteSQL(sql, strMsg)
 Call FillData(rs, KQGrid1)
End Function

Private Sub KQGrid1_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
   If Button = 2 Then
   
     Me.PopupMenu pop_mnu
     
   End If
End Sub

Private Sub pop_addInOutInfo_Click()
  frmAddInOutInfo.Show
  
  
End Sub




Private Sub pop_ChgInOutInfo_Click()
 frmChgInOutInfo.Show
 Unload Me
End Sub

Public Sub pop_DelInOutInfo_Click()
   Dim strInOut As String
 
  If KQGrid1.Rows <= 1 Then Exit Sub
  If KQGrid1.Row < 1 Then Exit Sub
  strInOut = KQGrid1.TextMatrix(KQGrid1.Row, 1)
  'MsgBox strInOut

  
  If MsgBox("你真的要删除该员工的上下班信息吗?", vbQuestion + vbYesNo) = vbYes Then
    Dim strSql As String
    Dim strMsg As String
    Dim rs As New ADODB.Recordset
    strSql = "delete * from AttendanceInfo where ID=" & strInOut
    Set rs = ExecuteSQL(strSql, strMsg)
    Call Form_Load
  End If
End Sub

Private Sub refresh_Click()
   Call Form_Load
End Sub

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -