deleting but saving db
RH

Forum home » Delegate support and help forum » Microsoft Access Training and help » Deleting but saving DB entries

Deleting but saving DB entries

resolvedResolved · Medium Priority · Version 2010

Stuart has attended:
Access Intermediate course
Access Advanced course
Access VBA course

Deleting but saving DB entries

I have 2 tables which link to 2 forms. One of the forms has a delete button which deletes permanently from both tables.

I'd like it to not just delete but save the info from both tables in another table (deleted clients) for future reference.

How can I achieve this?

RE: Deleting but saving DB entries

Hi Stuart

Before the records are deleted you could have your button run an append query that copies the record to the deleted clients table. If the field structures of the tables are the same then that would work with a single deleted clients table.

To identify which record is to be appended you could have a check box field on in the table and on the form. This could be set to True by the macro using the Setvalue command.

Please let me know a little more about your table structures and whether your button runs a macro or a vba procedure.

Regards

Doug Dunn
Best STL

RE: Deleting but saving DB entries

Hi Doug,

The tables are fairly straight forward tables (used to be one but I split it). I'm not sure how I would show you?

The delete button is an embedded macro.

Cheers,

Stuart

RE: Deleting but saving DB entries

Hi Stuart.

With the tables the same structure you should be able to append the records as I suggested. If you want to send an example email the zipped file to doug@stl-training.co.uk

Doug
Best STL

Fri 4 Oct 2013: Automatically marked as resolved.


 

Access tip:

Related tables

When you have related tables such as Customers and their Orders, the Customer table is the Primary table.

Open the Customers table in datasheet view and go to the Home Tab and Records group. Click on the More option and choose Subdatasheet and then click on Subdatasheet again. Now choose the related table (Orders) and click ok.

Now you can click the + symbol by each company to show the related orders.

View all Access hints and tips


Server loaded in 0.06 secs.