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

📄 frmzginfo.frm

📁 企业工资管理系统
💻 FRM
📖 第 1 页 / 共 2 页
字号:
         Height          =   375
         Index           =   7
         Left            =   1680
         TabIndex        =   23
         Text            =   "Text1"
         Top             =   2280
         Width           =   1335
      End
      Begin VB.TextBox Text1 
         DataField       =   "住址"
         DataSource      =   "Adodc1"
         Height          =   375
         Index           =   6
         Left            =   1680
         TabIndex        =   22
         Text            =   "Text1"
         Top             =   1800
         Width           =   4455
      End
      Begin VB.TextBox Text1 
         DataField       =   "学历"
         DataSource      =   "Adodc1"
         Height          =   375
         Index           =   5
         Left            =   4800
         TabIndex        =   21
         Text            =   "Text1"
         Top             =   1320
         Width           =   1335
      End
      Begin VB.TextBox Text1 
         DataField       =   "出生日期"
         DataSource      =   "Adodc1"
         Height          =   375
         Index           =   4
         Left            =   1680
         TabIndex        =   20
         Text            =   "Text1"
         Top             =   1320
         Width           =   1335
      End
      Begin VB.TextBox Text1 
         DataField       =   "籍贯"
         DataSource      =   "Adodc1"
         Height          =   375
         Index           =   3
         Left            =   4800
         TabIndex        =   19
         Text            =   "Text1"
         Top             =   840
         Width           =   1335
      End
      Begin VB.TextBox Text1 
         DataField       =   "性别"
         DataSource      =   "Adodc1"
         Height          =   375
         Index           =   2
         Left            =   1680
         TabIndex        =   18
         Text            =   "Text1"
         Top             =   840
         Width           =   1335
      End
      Begin VB.TextBox Text1 
         DataField       =   "员工姓名"
         DataSource      =   "Adodc1"
         Height          =   375
         Index           =   1
         Left            =   4800
         TabIndex        =   17
         Text            =   "Text1"
         Top             =   360
         Width           =   1335
      End
      Begin VB.TextBox Text1 
         DataField       =   "员工编号"
         DataSource      =   "Adodc1"
         Height          =   375
         Index           =   0
         Left            =   1680
         TabIndex        =   16
         Text            =   "Text1"
         Top             =   360
         Width           =   1335
      End
      Begin VB.Label Label1 
         BackStyle       =   0  'Transparent
         Caption         =   "联系电话:"
         BeginProperty Font 
            Name            =   "宋体"
            Size            =   12
            Charset         =   134
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Height          =   375
         Index           =   8
         Left            =   3480
         TabIndex        =   10
         Top             =   2280
         Width           =   1095
      End
      Begin VB.Label Label1 
         BackStyle       =   0  'Transparent
         Caption         =   "邮编:"
         BeginProperty Font 
            Name            =   "宋体"
            Size            =   12
            Charset         =   134
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Height          =   375
         Index           =   7
         Left            =   840
         TabIndex        =   9
         Top             =   2280
         Width           =   735
      End
      Begin VB.Label Label1 
         BackStyle       =   0  'Transparent
         Caption         =   "住址:"
         BeginProperty Font 
            Name            =   "宋体"
            Size            =   12
            Charset         =   134
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Height          =   375
         Index           =   6
         Left            =   840
         TabIndex        =   8
         Top             =   1800
         Width           =   735
      End
      Begin VB.Label Label1 
         BackStyle       =   0  'Transparent
         Caption         =   "学历:"
         BeginProperty Font 
            Name            =   "宋体"
            Size            =   12
            Charset         =   134
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Height          =   375
         Index           =   5
         Left            =   3960
         TabIndex        =   7
         Top             =   1320
         Width           =   615
      End
      Begin VB.Label Label1 
         BackStyle       =   0  'Transparent
         Caption         =   "出生日期:"
         BeginProperty Font 
            Name            =   "宋体"
            Size            =   12
            Charset         =   134
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Height          =   375
         Index           =   4
         Left            =   360
         TabIndex        =   6
         Top             =   1320
         Width           =   1215
      End
      Begin VB.Label Label1 
         BackStyle       =   0  'Transparent
         Caption         =   "籍贯:"
         BeginProperty Font 
            Name            =   "宋体"
            Size            =   12
            Charset         =   134
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Height          =   375
         Index           =   3
         Left            =   3960
         TabIndex        =   5
         Top             =   840
         Width           =   615
      End
      Begin VB.Label Label1 
         BackStyle       =   0  'Transparent
         Caption         =   "性别:"
         BeginProperty Font 
            Name            =   "宋体"
            Size            =   12
            Charset         =   134
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Height          =   375
         Index           =   2
         Left            =   840
         TabIndex        =   4
         Top             =   840
         Width           =   615
      End
      Begin VB.Label Label1 
         BackStyle       =   0  'Transparent
         Caption         =   "员工姓名:"
         BeginProperty Font 
            Name            =   "宋体"
            Size            =   12
            Charset         =   134
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Height          =   375
         Index           =   1
         Left            =   3480
         TabIndex        =   3
         Top             =   360
         Width           =   1215
      End
      Begin VB.Label Label1 
         BackStyle       =   0  'Transparent
         Caption         =   "员工编号:"
         BeginProperty Font 
            Name            =   "宋体"
            Size            =   12
            Charset         =   134
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Height          =   375
         Index           =   0
         Left            =   360
         TabIndex        =   2
         Top             =   360
         Width           =   1215
      End
   End
   Begin VB.Label Label1 
      BackStyle       =   0  'Transparent
      Caption         =   "备注:"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   12
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Index           =   14
      Left            =   1080
      TabIndex        =   32
      Top             =   5280
      Width           =   615
   End
End
Attribute VB_Name = "frmZGInfo"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False



Private Sub Command1_Click()
Adodc1.Recordset.MoveFirst
Command1.Enabled = False
Command2.Enabled = True
Command3.Enabled = True
Command4.Enabled = False
Command5.Enabled = True
Command6.Enabled = True
Command7.Enabled = True
Command8.Enabled = True
Command9.Enabled = True
End Sub

Private Sub Command2_Click()
   Adodc1.Recordset.MoveNext
If Adodc1.Recordset.EOF = True Then
   Adodc1.Recordset.MovePrevious
   MsgBox "已到达最后一条记录!", vbOKOnly + vbExclamation, "警告"
   Exit Sub
End If
Command4.Enabled = True
Command1.Enabled = True

End Sub

Private Sub Command3_Click()
Adodc1.Recordset.MoveLast
Command1.Enabled = True
Command2.Enabled = False
Command3.Enabled = False
Command4.Enabled = True
Command5.Enabled = True
Command6.Enabled = True
Command7.Enabled = True
Command8.Enabled = True
Command9.Enabled = True
End Sub

Private Sub Command4_Click()
   Adodc1.Recordset.MovePrevious
If Adodc1.Recordset.BOF = True Then
   Adodc1.Recordset.MoveNext
   MsgBox "已到达第一条记录!", vbOKOnly + vbExclamation, "警告"
End If
   Command2.Enabled = True
   Command3.Enabled = True
End Sub

Private Sub Command5_Click()
Adodc1.Recordset.AddNew

'For i = 0 To 14
'   Text1(i) = ""
'Next i

Text1(0).SetFocus
Command1.Enabled = False
Command2.Enabled = False
Command3.Enabled = False
Command4.Enabled = False
Command5.Enabled = False
Command6.Enabled = False
Command7.Enabled = False
Command8.Enabled = True
Command9.Enabled = True
End Sub

Private Sub Command6_Click()
If MsgBox("确定删除当前资料吗?", vbInformation + vbYesNo, "删除资料?") = vbYes Then
   Adodc1.Recordset.Delete
   'Adodc1.Refresh
   Adodc1.Recordset.MovePrevious
End If
End Sub

Private Sub Command7_Click()
Command1.Enabled = False
Command2.Enabled = False
Command3.Enabled = False
Command4.Enabled = False
Command5.Enabled = False
Command6.Enabled = False
Command7.Enabled = False
Command8.Enabled = True
Command9.Enabled = True
End Sub

Private Sub Command8_Click()
For i = 0 To 14
   If Text1(i) = "" Then
      MsgBox "输入不完整!", vbOKOnly + vbExclamation, "警告"
      Text1(i).SetFocus
      Exit Sub
   End If
Next i

 If MsgBox("确定保存当前资料吗?", vbInformation + vbYesNo, "保存资料?") = vbYes Then
    Adodc1.Recordset.Fields("员工编号") = Text1(0).Text
    Adodc1.Recordset.Fields("员工姓名") = Text1(1).Text
    Adodc1.Recordset.Fields("性别") = Text1(2).Text
    Adodc1.Recordset.Fields("籍贯") = Text1(3).Text
    Adodc1.Recordset.Fields("出生日期") = Text1(4).Text
    Adodc1.Recordset.Fields("学历") = Text1(5).Text
    Adodc1.Recordset.Fields("住址") = Text1(6).Text
    Adodc1.Recordset.Fields("邮编") = Text1(7).Text
    Adodc1.Recordset.Fields("联系电话") = Text1(8).Text
    Adodc1.Recordset.Fields("所属部门编号") = Text1(9).Text
    Adodc1.Recordset.Fields("所属部门名称") = Text1(10).Text
    Adodc1.Recordset.Fields("职务") = Text1(11).Text
    Adodc1.Recordset.Fields("参加工作时间") = Text1(12).Text
    Adodc1.Recordset.Fields("进入公司时间") = Text1(13).Text
    Adodc1.Recordset.Fields("备注") = Text1(14).Text
    
    Adodc1.Recordset.MoveFirst
 End If
 
 Command1.Enabled = True
 Command2.Enabled = True
 Command3.Enabled = True
 Command4.Enabled = True
 Command5.Enabled = True
 Command6.Enabled = True
 Command7.Enabled = True
 Command8.Enabled = False
 Command9.Enabled = True

End Sub

Private Sub Command9_Click()
 If MsgBox(" 放弃当前的操作并退出吗?", vbInformation + vbYesNo, "放弃并退出?") = vbYes Then
    Adodc1.Recordset.CancelBatch adAffectAllChapters
    Me.Hide
    Unload Me
   Exit Sub
End If
End Sub

Private Sub Form_Load()

Command1.Enabled = True
Command2.Enabled = True
Command3.Enabled = True
Command4.Enabled = True
Command5.Enabled = True
Command6.Enabled = True
Command7.Enabled = True
Command8.Enabled = False
Command9.Enabled = True

End Sub

⌨️ 快捷键说明

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