Save deleted records in another database

ABDULFATAH

Registered User.
Local time
Today, 22:58
Joined
Oct 22, 2001
Messages
11
How to add a code to the delete button to automatically save the deleted record to another table in the same database or another database ?
 
You need to create a table to copy deleted (archived) files into that mirrors the target table where the data is stored.

Then an append query needs to be created using the table with the stored data in being copied to the newly created table.

You now need to attach this append query to a delete button on the form using the following VBA Code:

DoCmd.OpenQuery "Nameofappendquery", , acReadOnly

This should be inserted before the delete command lines.
 
I tried what suggested but it append all the records and not current record. Is there away to append the curent record about to delete.
 
You need to add criteria to the query so it knows which record to append.
 

Users who are viewing this thread

Back
Top Bottom