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

📄 f_fulifeicx.frm

📁 用Visual basic6开发的人事信息管理系统,数据库采用的是Sql Server2000
💻 FRM
📖 第 1 页 / 共 2 页
字号:
         TabIndex        =   5
         Top             =   832
         Width           =   1935
         _ExtentX        =   3413
         _ExtentY        =   529
         _Version        =   393216
         CheckBox        =   -1  'True
         DateIsNull      =   -1  'True
         Format          =   69206017
         CurrentDate     =   36187
      End
      Begin VB.TextBox txtFields 
         Appearance      =   0  'Flat
         DataField       =   "用工类型"
         Height          =   285
         Index           =   6
         Left            =   6600
         TabIndex        =   10
         Top             =   2040
         Width           =   1935
      End
      Begin Threed.SSCommand CmdXianShi_Exit 
         Height          =   375
         Left            =   8280
         TabIndex        =   41
         Top             =   3720
         Width           =   1095
         _Version        =   65536
         _ExtentX        =   1931
         _ExtentY        =   661
         _StockProps     =   78
         Caption         =   "&E.关 闭"
      End
      Begin VB.Label lblLabels 
         Caption         =   "年  度"
         Height          =   255
         Index           =   0
         Left            =   240
         TabIndex        =   34
         Top             =   375
         Width           =   855
      End
      Begin VB.Label lblLabels 
         Caption         =   "月  份"
         Height          =   255
         Index           =   1
         Left            =   4800
         TabIndex        =   33
         Top             =   375
         Width           =   855
      End
      Begin VB.Label lblLabels 
         Caption         =   "部  门"
         Height          =   255
         Index           =   2
         Left            =   4800
         TabIndex        =   32
         Top             =   1455
         Width           =   855
      End
      Begin VB.Label lblLabels 
         Caption         =   "岗  位"
         Height          =   255
         Index           =   3
         Left            =   240
         TabIndex        =   31
         Top             =   2055
         Width           =   1215
      End
      Begin VB.Label lblLabels 
         Caption         =   "员工号"
         Height          =   255
         Index           =   4
         Left            =   4800
         TabIndex        =   30
         Top             =   855
         Width           =   855
      End
      Begin VB.Label lblLabels 
         Caption         =   "姓  名"
         Height          =   255
         Index           =   5
         Left            =   240
         TabIndex        =   29
         Top             =   1455
         Width           =   615
      End
      Begin VB.Label lblLabels 
         Caption         =   "时  间"
         Height          =   255
         Index           =   6
         Left            =   240
         TabIndex        =   28
         Top             =   855
         Width           =   615
      End
      Begin VB.Label lblLabels 
         Caption         =   "费用类型"
         Height          =   255
         Index           =   7
         Left            =   240
         TabIndex        =   27
         Top             =   2655
         Width           =   855
      End
      Begin VB.Label lblLabels 
         Caption         =   "费用项目"
         Height          =   255
         Index           =   8
         Left            =   4800
         TabIndex        =   26
         Top             =   2655
         Width           =   855
      End
      Begin VB.Label lblLabels 
         Caption         =   "费用金额"
         Height          =   255
         Index           =   9
         Left            =   240
         TabIndex        =   25
         Top             =   3255
         Width           =   855
      End
      Begin VB.Label lblLabels 
         Caption         =   "用工类型"
         Height          =   255
         Index           =   10
         Left            =   4800
         TabIndex        =   24
         Top             =   2055
         Width           =   855
      End
   End
End
Attribute VB_Name = "F_FuliFeiCX"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Dim WithEvents rs As Recordset
Attribute rs.VB_VarHelpID = -1
Dim WithEvents adoPrimaryRS As Recordset
Attribute adoPrimaryRS.VB_VarHelpID = -1
Dim WithEvents adoXianshiRS As Recordset
Attribute adoXianshiRS.VB_VarHelpID = -1
Dim Row_ID As String  '为找到ID 的查询SQL 语句


Private Sub Check1_Click()
If Check1.Value = 1 Then
    Check2.Value = 0
    Check3.Value = 0
    Combo1.Clear
    
    Sql = "select distinct 姓名 from 福利费用"
    Set rs = db.Execute(Sql)
    
    Do While Not rs.EOF
            If IsNull(rs("姓名")) = False Then
                Combo1.AddItem rs("姓名")
            End If
            rs.MoveNext
    Loop
    Combo1.Visible = True
    Combo2.Visible = False
    Combo3.Visible = False
    
    Frame2.Visible = False
    Frame3.Visible = False
End If
End Sub

Private Sub Check2_Click()
If Check2.Value = 1 Then
   
    Check1.Value = 0
    Check3.Value = 0
    Combo2.Clear
    
    Sql = "select distinct 部门 from 福利费用"
    Set rs = db.Execute(Sql)
    
    Do While Not rs.EOF
            If IsNull(rs("部门")) = False Then
                Combo2.AddItem rs("部门")
            End If
            rs.MoveNext
    Loop
    Combo2.Visible = True
    Combo1.Visible = False
    Combo3.Visible = False
    
    
    Frame2.Visible = False
    Frame3.Visible = False
End If
End Sub


Private Sub Check3_Click()

If Check3.Value = 1 Then
    Check1.Value = 0
    Check2.Value = 0
    Combo3.Clear
    
    Sql = "select distinct 费用项目 from 福利费用"
    Set rs = db.Execute(Sql)
    
    Do While Not rs.EOF
            If IsNull(rs("费用项目")) = False Then
                Combo3.AddItem rs("费用项目")
            End If
            rs.MoveNext
    Loop
    Combo3.Visible = True
    Combo1.Visible = False
    Combo2.Visible = False
    
    
    Frame2.Visible = False
    Frame3.Visible = False
End If


End Sub

Private Sub CmdXianShi_Exit_Click()
Frame2.Visible = True
Frame3.Visible = False
End Sub

Private Sub Command1_Click()
Dim DataGrid_sql  As String  '数据表格中的数据源
Dim oText As TextBox
If Check1.Value = 1 Then
    DataGrid_sql = "select * from 福利费用 where 姓名 ='" & Combo1.Text & "'  and  时间   between ' " & DTPicker1 & " ' and ' " & DTPicker2 & " '"
        
    Set adoPrimaryRS = New Recordset
    adoPrimaryRS.Open DataGrid_sql, db, adOpenStatic, adLockOptimistic

    Set DataGrid1.DataSource = adoPrimaryRS
    
          
    Frame3.Visible = False
    Frame2.Visible = True
   
   End If

   If Check2.Value = 1 Then
        
     DataGrid_sql = "select * from 福利费用 where 部门 ='" & Combo2.Text & "'  and  时间   between ' " & DTPicker1 & " ' and ' " & DTPicker2 & " '"
       
     Set adoPrimaryRS = New Recordset
     adoPrimaryRS.Open DataGrid_sql, db, adOpenStatic, adLockOptimistic
 
     Set DataGrid1.DataSource = adoPrimaryRS
    
          
     Frame3.Visible = False
     Frame2.Visible = True
     
    End If
    
    If Check3.Value = 1 Then
    
      DataGrid_sql = "select * from 福利费用 where 费用项目 ='" & Combo3.Text & "'  and  时间   between ' " & DTPicker1 & " ' and ' " & DTPicker2 & " '"
    
      Set adoPrimaryRS = New Recordset
      adoPrimaryRS.Open DataGrid_sql, db, adOpenStatic, adLockOptimistic

      Set DataGrid1.DataSource = adoPrimaryRS
    
          
      Frame3.Visible = False
      Frame2.Visible = True
    End If
    
    
   
End Sub

Private Sub Command2_Click()
RSGL.Enabled = True
Unload Me
End Sub

Private Sub Command3_Click()
Dim XianShi_sql    As String '单条数据显示的数据源
  
  
  If Row_ID = "" Then
    MsgBox "请您选择其中一条信息!"
    Exit Sub
  Else
    XianShi_sql = "select * from 福利费用 where ID = " & Row_ID
    
    Set adoXianshiRS = New Recordset
    adoXianshiRS.Open XianShi_sql, db, adOpenStatic, adLockOptimistic
         
   
    For Each oText In Me.txtFields
          Set oText.DataSource = adoXianshiRS
    Next
    
    Set DTPicker3.DataSource = adoXianshiRS

   
  
End If
  
  Frame2.Visible = False
  Frame3.Visible = True
       
End Sub

Private Sub DataGrid1_Click()

  If Not adoPrimaryRS.BOF And Not adoPrimaryRS.EOF Then
      If Not IsNull(adoPrimaryRS.Fields("ID")) Then
          Row_ID = adoPrimaryRS.Fields("ID")
      Else
          MsgBox "请您选择其中一条信息!"
      End If
   Else
    Exit Sub
  End If
  
End Sub

Private Sub Form_Load()
Frame2.Visible = False
Frame3.Visible = False
For Each oText In Me.txtFields
   oText.Locked = True
Next

DTPicker3.Enabled = True
Me.DTPicker1.Value = Format(Now, "yyyy年mm月dd日")
Me.DTPicker2.Value = Format(Now, "yyyy年mm月dd日")
 
           
End Sub




⌨️ 快捷键说明

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