Dim mblchange As Boolean
Public txtSQL As String
Public msgtext As String
Dim mrc As ADODB.Recordset
Private Sub cmdcancle_Click()
Unload Me
End Sub
Private Sub cmdOK_Click()
Dim intCount As Integer
Dim txtSQL As String
Dim MsgString As String
Dim sMeg As String
Dim i As Integer
For intCount = 0 To 1
If Trim(Text1(intCount) & "") = "" Then
Select Case intCount
Case 0
sMeg = "工号"
Case 1
sMeg = "姓名"
End Select
sMeg = sMeg & "不能为空"
MsgBox sMeg, vbOKOnly + vbExclamation, "警告"
Text1(intCount).SetFocus
Exit Sub
End If
Next intCount
If Trim(Text1(3) & "") = "" Then
MsgBox "出生日期不能为空", vbOKOnly + vbExclamation, "警告"
End If
If Trim(Text1(3) & "") <> "" Then
If Not IsDate(Text1(3)) Then
MsgBox "出生日期应为(yyyy-mm-dd)!", vbOKOnly + vbExclamation, "警告"
Text1(3).SetFocus
Exit Sub
Else
Text1(3) = Format(Text1(3), "yyyy-mm-dd")
End If
End If
If Trim(Text1(2) & "") = "" Then
MsgBox "年龄不能为空", vbOKOnly + vbExclamation, "警告"
课程设计说明书 NO.23
Exit Sub
End If
If gintMode = 1 Then
txtSQL = "select * from dangan where ygid='" & Trim(Text1(0)) & "'"
Set mrc = ExecuteSQL(txtSQL, msgtext)
If mrc.EOF = False Then
MsgBox "有重复记录", vbOKOnly + vbExclamation, "警告"
Text1(0).SetFocus
End If
mrc.Close
txtSQL = "delete * from dangan where ygid='" & Trim(Text1(0)) & "'"
Set mrc = ExecuteSQL(txtSQL, msgtext)
Next intCount
For intCount = 2 To 5
mrc.Fields(intCount) = Trim(Text1(intCount))
Next intCount
For intCount = 6 To 10
mrc.Fields(intCount) = Trim(Text1(intCount))
若图片无法显示请联系QQ752018766,数据库课程设计-人事工资管理系统 第8页免费,转发
请注明源于www.751com.cn
frmmanrecord.ShowTitle
frmmanrecord.ShowData
frmmanrecord.ZOrder 1
End If
Private Sub cmdSave_Click()
Dim intCount As Integer
Dim sMeg As String
Dim rectemp As Recordset
课程设计说明书 NO.24
Dim sSql As String
Dim msgtext As String
For intCount = 0 To 3
If Trim(txtItem(intCount) & " ") = "" Then
Select Case intCount
Case 0
sMeg = "本月天数"
Case 2
sMeg = "应出勤天数"
Case 3
上一页 [1] [2] [3] [4] [5] [6] [7] [8] [9] 下一页