THis worked for me, but did not initially?
Code:
Sub TestParameters()
Dim BD As Date, ED As Date
BD = DateAdd("yyyy", -9, Date)
ED = DateAdd("yyyy", -1, Date)
DoCmd.SetParameter "BeginDate", BD
DoCmd.SetParameter "EndDate", ED
DoCmd.OpenQuery "qryParameters"
End Sub
Code:
PARAMETERS BD DateTime, ED DateTime;
SELECT TestTransactions.ID, TestTransactions.TransactionDate
FROM TestTransactions
WHERE (((TestTransactions.TransactionDate) Between [BD] And [ED]));
and it should not have, as I had the paremeter names wrong? 
I changed the names and got the prompt. Sometimes I do and sometimes I do not, and it runs fine?