Invalid Bracketing error

G

Guest

I have been editing a database I did not create. I copied an existing querie
and pasted the criteria syntax from the original. I keep getting the
following error:

"Invalid racking of name '[forms!frmReportsMenu!txtRptBeginDate]'

even though I put the following :

Between ([forms]![frmReportsMenu]![txtRptBeginDate]) And
([Forms]![frmReportsMenu]![txtRptEndDate])

I have checked the SQL view as well .... the text is identical but it keeps
coming back to this error. I even tried creating the querie from scratch I
still get the same error.

Any suggestions as to a resolution would be greatly appreciated

Thanks,
DBrown
 
N

Nikos Yannacopoulos

Try to remove the round brackets around the control references.

HTH,
Nikos
 
J

John Spencer

Open the query in SQL view (View: SQL)

I suspect that the invalid bracketing might be in the parameter declaration
section. The query could start with

Parameters [forms!frmReportsMenu!txtRptBeginDate] DateTime, ...

If it does, then fix the bracketing to be
[forms]![frmReportsMenu]![txtRptBeginDate] and check the bracketing around
txtRptEndDate also.

If that is not the case, then look elsewhere in the query string to see if
you can find [forms!frmReportsMenu!txtRptBeginDate] it anywhere. If you
still have a problem, copy and paste the text string to group and let
additional sets of eyes look at your query.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top