I didn't catch that before. Try:
DoCmd.RunCommand acCmdDeleteRecord
in place of your delete statment.
JimD.