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

📄 frmquerydeal.frm

📁 人事工资管理系统应包含对员工档案、员工培训、员工调动、员工职称评定、员工奖惩的管理和工资的查询与管理等诸多模块。员工档案管理模块对员工信息进行添加、修改、删除和查询;员工培训管理模块可增加
💻 FRM
字号:
VERSION 5.00
Object = "{F0D2F211-CCB0-11D0-A316-00AA00688B10}#1.0#0"; "MSDATLST.OCX"
Object = "{BEEECC20-4D5F-4F8B-BFDC-5D9B6FBDE09D}#1.0#0"; "vsFlex8.ocx"
Begin VB.Form FrmQueryDeal 
   BorderStyle     =   3  'Fixed Dialog
   Caption         =   "查询奖惩记录"
   ClientHeight    =   5625
   ClientLeft      =   45
   ClientTop       =   330
   ClientWidth     =   7200
   Icon            =   "FrmQueryDeal.frx":0000
   LinkTopic       =   "Form1"
   LockControls    =   -1  'True
   MaxButton       =   0   'False
   MDIChild        =   -1  'True
   MinButton       =   0   'False
   ScaleHeight     =   5625
   ScaleWidth      =   7200
   ShowInTaskbar   =   0   'False
   Begin VSFlex8Ctl.VSFlexGrid VSDataComment 
      Height          =   3975
      Left            =   120
      TabIndex        =   11
      Top             =   1440
      Width           =   6975
      _cx             =   12303
      _cy             =   7011
      Appearance      =   1
      BorderStyle     =   1
      Enabled         =   -1  'True
      BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
         Name            =   "宋体"
         Size            =   9
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      MousePointer    =   0
      BackColor       =   -2147483643
      ForeColor       =   -2147483640
      BackColorFixed  =   -2147483633
      ForeColorFixed  =   -2147483630
      BackColorSel    =   -2147483635
      ForeColorSel    =   -2147483634
      BackColorBkg    =   -2147483636
      BackColorAlternate=   -2147483643
      GridColor       =   -2147483633
      GridColorFixed  =   -2147483632
      TreeColor       =   -2147483632
      FloodColor      =   192
      SheetBorder     =   -2147483642
      FocusRect       =   1
      HighLight       =   1
      AllowSelection  =   -1  'True
      AllowBigSelection=   -1  'True
      AllowUserResizing=   0
      SelectionMode   =   0
      GridLines       =   1
      GridLinesFixed  =   2
      GridLineWidth   =   1
      Rows            =   50
      Cols            =   10
      FixedRows       =   1
      FixedCols       =   1
      RowHeightMin    =   0
      RowHeightMax    =   0
      ColWidthMin     =   0
      ColWidthMax     =   0
      ExtendLastCol   =   0   'False
      FormatString    =   ""
      ScrollTrack     =   0   'False
      ScrollBars      =   3
      ScrollTips      =   0   'False
      MergeCells      =   0
      MergeCompare    =   0
      AutoResize      =   -1  'True
      AutoSizeMode    =   0
      AutoSearch      =   0
      AutoSearchDelay =   2
      MultiTotals     =   -1  'True
      SubtotalPosition=   1
      OutlineBar      =   0
      OutlineCol      =   0
      Ellipsis        =   0
      ExplorerBar     =   0
      PicturesOver    =   0   'False
      FillStyle       =   0
      RightToLeft     =   0   'False
      PictureType     =   0
      TabBehavior     =   0
      OwnerDraw       =   0
      Editable        =   0
      ShowComboButton =   1
      WordWrap        =   0   'False
      TextStyle       =   0
      TextStyleFixed  =   0
      OleDragMode     =   0
      OleDropMode     =   0
      DataMode        =   0
      VirtualData     =   -1  'True
      DataMember      =   ""
      ComboSearch     =   3
      AutoSizeMouse   =   -1  'True
      FrozenRows      =   0
      FrozenCols      =   0
      AllowUserFreezing=   0
      BackColorFrozen =   0
      ForeColorFrozen =   0
      WallPaperAlignment=   9
      AccessibleName  =   ""
      AccessibleDescription=   ""
      AccessibleValue =   ""
      AccessibleRole  =   24
   End
   Begin VB.CommandButton CmdClose 
      Caption         =   "关闭(&C)"
      Height          =   375
      Left            =   5880
      TabIndex        =   5
      Top             =   960
      Width           =   1215
   End
   Begin VB.CommandButton CmdQuery 
      Caption         =   "查询(&Q)"
      Default         =   -1  'True
      Height          =   375
      Left            =   4560
      TabIndex        =   4
      Top             =   960
      Width           =   1215
   End
   Begin VB.PictureBox PicFrame 
      Height          =   735
      Index           =   1
      Left            =   120
      ScaleHeight     =   675
      ScaleWidth      =   6915
      TabIndex        =   0
      Top             =   120
      Width           =   6975
      Begin MSDataListLib.DataCombo CmbCode 
         Height          =   330
         Left            =   1440
         TabIndex        =   10
         Top             =   120
         Width           =   1815
         _ExtentX        =   3201
         _ExtentY        =   582
         _Version        =   393216
         Text            =   ""
      End
      Begin VB.TextBox TxtName 
         Height          =   330
         Left            =   5040
         TabIndex        =   1
         Top             =   150
         Width           =   1695
      End
      Begin VB.CheckBox ChkCode 
         Caption         =   "按员工编号:"
         Height          =   255
         Left            =   120
         TabIndex        =   3
         Top             =   188
         Width           =   1575
      End
      Begin VB.CheckBox ChkName 
         Caption         =   "员工姓名:"
         Height          =   255
         Left            =   3720
         TabIndex        =   2
         Top             =   188
         Width           =   1215
      End
   End
   Begin VB.PictureBox WinXPQueryComment 
      Height          =   480
      Left            =   1440
      ScaleHeight     =   420
      ScaleWidth      =   1140
      TabIndex        =   9
      Top             =   120
      Width           =   1200
   End
   Begin VB.Label LblLable 
      AutoSize        =   -1  'True
      Caption         =   "当前查询记录共:"
      Height          =   180
      Index           =   3
      Left            =   120
      TabIndex        =   8
      Top             =   1050
      Width           =   1440
   End
   Begin VB.Label LblCount 
      AutoSize        =   -1  'True
      Height          =   180
      Left            =   1800
      TabIndex        =   7
      Top             =   1050
      Width           =   90
   End
   Begin VB.Label LblLable 
      AutoSize        =   -1  'True
      Caption         =   "条"
      Height          =   180
      Index           =   2
      Left            =   2160
      TabIndex        =   6
      Top             =   1050
      Width           =   180
   End
End
Attribute VB_Name = "FrmQueryDeal"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub CmbCode_Change()
If RstQComment.State = adStateOpen Then
RstQComment.Close              '//关闭记录集
End If
RstQComment.Open "select *from 奖惩管理 where 员工编号='" & CmbCode.Text & "'", DBCON, adOpenKeyset, adLockOptimistic, adCmdText
 'TxtName.Text = RstQComment.Fields(1).Value          '//给文本框赋值
End Sub

Private Sub CmdClose_Click()
Unload Me
End Sub

Private Sub CmdQuery_Click()
Dim StrSQL As String
    StrSQL = "select * from 奖惩管理 where "        '//给定义好的字符变量赋予SQL语句
    '//判断复选框有一个选中时,则
    If ChkCode.Value = 1 Or ChkName.Value = 1 Then
        '//判断二个复选框同时选中时,则
        If ChkCode.Value = 1 And ChkName.Value = 1 Then
            StrSQL = StrSQL & "员工编号= '" & Trim(CmbCode.Text) & "'" & "and" & " 员工姓名 = '" & Trim(TxtName.Text) & "'"
        '//判断编号与姓名复选框选中时,则
        ElseIf ChkCode.Value = 1 And ChkName.Value = 1 Then
              StrSQL = StrSQL & "员工编号= '" & Trim(CmbCode.Text) & "'" & "and" & " 员工姓名 = '" & Trim(TxtName.Text) & "'"
        ElseIf ChkCode.Value = 1 Then
            StrSQL = StrSQL & "员工编号= '" & Trim(CmbCode.Text) & "'"
          ElseIf ChkName.Value = 1 Then
            StrSQL = StrSQL & " 员工姓名 = '" & Trim(TxtName.Text) & "'"
        Else
            If ChkCode.Value = 1 Then   '//只有编号复选框选中时,则
            StrSQL = StrSQL & "员工编号= '" & Trim(CmbCode.Text) & "'"
            End If
            If ChkName.Value = 1 Then   '//只有姓名复选框选中时,则
                StrSQL = StrSQL & " 员工姓名 = '" & Trim(TxtName.Text) & "'"
            End If
        End If
            If RstQueryComment.State = adStateClosed Then
                RstQueryComment.Open StrSQL, DBCON, adOpenKeyset, adLockOptimistic, adCmdText
            End If
            
            Set VSDataComment.DataSource = RstQueryComment.DataSource
            LblCount.Caption = RstQueryComment.RecordCount        '//将记录条数显示在标签上
            VSDataComment.Refresh        '//刷新网格
            RstQueryComment.Close             '//关闭记录集
            CmbCode.Text = Empty        '//请空文本框
            TxtName.Text = Empty
    '        TxtYear.Text = Empty
            'CmbMonth.Text = Empty
        Else
            If RsQueryComment.State = adStateClosed Then
                RsQueryComment.Open "奖惩管理", DBCON, adOpenKeyset, adLockOptimistic, adCmdTable
            End If
                Set VSDataComment.DataSource = RsQueryComment.DataSource     '//设置网格的数据源
                LblCount.Caption = RsQueryComment.RecordCount
                VSDataComment.Refresh        '//刷新网格
                RsQueryComment.Close             '//关闭记录集
                CmbCode.Text = Empty        '//请空文本框
                TxtName.Text = Empty
        '        TxtYear.Text = Empty
                'CmbMonth.Text = Empty
        End If
End Sub

Private Sub Form_Load()
'WinXPQueryComment.InitSubClassing
Me.Left = Frmmdimain.Width / 3
Me.Top = 0

If RsQComment.State = adStateOpen Then
    RsQComment.Close
End If
RsQComment.Open "奖惩管理", DBCON, adOpenKeyset, adLockPessimistic, adCmdTable
If RsQComment.RecordCount > 0 Then                '//如果记录集中有记录
    Set CmbCode.RowSource = RsQComment            '//DATACOMBO中的数据等于记录集
    CmbCode.BoundColumn = "员工编号"            '//绑定列
    CmbCode.ListField = "员工编号"
Else    '//否则。清空
    CmbCode.Text = ""
End If
End Sub

⌨️ 快捷键说明

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