1 Private Sub OddDesc_AfterUpdate()
2 Dim db As dao.database
3 Dim rs As dao.Recordset
4 Set db = CurrentDb()
5 Set rs = db.openrecordset("select * from addmanage")
6 If Me.OddManage = 5 Then
7 With rs
8 .AddNew
9 rs.Fields("serial") = Me.OddManage.Value
10 rs.Fields("manage") = Me.OddDesc.Value
11 .Update
12 End With
13 End If
14 End Sub
作者: leung 时间: 2007-3-16 17:47
已解决,在VB编辑窗口内的“工具”-“引用”,将“Microsoft DAO 3.6 Object Library"打勾就可以解决这个错误提示了