Deleting records from forms and subforms

  • Thread starter Thread starter Kev Spick
  • Start date Start date
K

Kev Spick

I have a data entry form containing a subform. I have
created a Delete button using the wizard but when i click
it i get an error that the subform contains related
records. Does anyone know a way that i can create a button
that deletes a record and also the related subform records
entered?
 
From the Tools menu, choose Relationships.

In the relationships window, there should be a line joining the main form
table and the subform table. Double-click it. Check the box for "Cascading
Deletes".

Now whenever you delete a record from the main table, the related records in
the secondary table will also be deleted.
 
Back
Top