معرفش اذا كانت هذه الاكواد تعمل معك ام لا لكن يمكن ان تجرب
للاضافة
Dim db As DAO.Database
Dim rst As DAO.Recordset
Set db = CurrentDb
Set rst = db.OpenRecordset("TablName", dbOpenDynaset)
With rst
.AddNew
![Name1] = me.txt1
![Name2] = me.txt2
.Update
.Close
End With
Set rst = Nothing
db.Close
Set db = Nothing
للتعديل
Dim db As DAO.Database
Dim rst As DAO.Recordset
Set db = CurrentDb
Set rst = db.OpenRecordset("TablName", dbOpenDynaset)
With rst
.FindFirst Criteria:="[ID]="&me.txtID
If Not .NoMatch Then
.Edit
![Name1] = me.txt1
![Name2] = me.txt2
.Update
End If
.Close
End With
Set rst = Nothing
db.Close
Set db = Nothing