The following code is being used to delete a record. When the delete query is executed from the navigation pane it works properly, but when the delete query is executed programmatically it deletes the first record in the table.
DoCmd.SetWarnings False
DoCmd.OpenQuery "QdelRequirementDelete"
DoCmd.SetWarnings True
DoCmd.Close
DoCmd.OpenForm "Volunteer Menu"
and the query
Field: Job Nbr Course Nbr
Table: Requirement Table Requirement Table
Delete: Where Where
Criteria:[Forms]![FrmRequirementDelete]![Job Nbr] [Forms]![FrmRequirementDelete]![Course Nbr]
Any help appreciated