[AccessD] RunCommand acCmdDeleteRecord deleted data in from JOINed tables?

Ryan W wrwehler at gmail.com
Tue Sep 21 12:12:48 CDT 2021


I have a form, Checklist, it's RecordSource WAS WorkOrderChecklist.

I then attempted to join WorkOrderCheckList with WorkOrder for the
datasource to get data about the workorder to display on the Checklist form.

the ribbon has a button "delete"0 that calls a function and sets the form /
control in focus and runs:

DoCmd.RunCommand acCmdSelectRecord
DoCmd.RunCommand acCmdDeleteRecord

In doing so, not only is the data in WorkOrderChecklist gone but the
WorkOrder table itself (OOPS).

Is this expected behavior?  I might have to tweak my delete button in the
ribbon to target the table instead of the selected record if that's the
case.


I found this blog post that more or less illustrates a similar issue:
https://vip.halderconsulting.com/index.php/knowledgebase/8/acCmdDeleteRecord---unintended-problems.html


More information about the AccessD mailing list