J
Joaquin
I've seen two ways to delete a record:
1.) DoCmd.RunCommand acCmdDeleteRecord
2.) DoCmd.RunSQL ("DELETE FROM MY_TABLE WHERE
[frmMyForm].Form![PRIMARY_KEY]=" +
Str(Me.tbxPrimaryKey))
I assume that the first only works on the current record a form in focus and
the second could potentially delete multiple records on other recordsets. ??
I was wondering if these asumptions are accurate and whether there are other
advantages to either in the context of the following form events:
- On Delete
- Before Del Confirm
- After Del Confirm
Thanks in advance for your consideration.
1.) DoCmd.RunCommand acCmdDeleteRecord
2.) DoCmd.RunSQL ("DELETE FROM MY_TABLE WHERE
[frmMyForm].Form![PRIMARY_KEY]=" +
Str(Me.tbxPrimaryKey))
I assume that the first only works on the current record a form in focus and
the second could potentially delete multiple records on other recordsets. ??
I was wondering if these asumptions are accurate and whether there are other
advantages to either in the context of the following form events:
- On Delete
- Before Del Confirm
- After Del Confirm
Thanks in advance for your consideration.