Error code 2585
am 09.05.2006 22:21:19 von lex_tiger3
I have a Report that gets data from a combo box that I created in a
form. On the form I have a command button that opens a report OnClick
and I also have a cancel button created to close the form OnClick if
the user decides not to open a report. The error code 2585 appears
when I click the cancel button and the report displays a parameter
query for the information that wasn't included by the form. I want the
cancel button to close the form and report and go back to the
switchboard menu. How can I fix this?
Re: Error code 2585
am 11.05.2006 10:05:47 von Salad
lex_tiger3@hotmail.com wrote:
> I have a Report that gets data from a combo box that I created in a
> form. On the form I have a command button that opens a report OnClick
> and I also have a cancel button created to close the form OnClick if
> the user decides not to open a report. The error code 2585 appears
> when I click the cancel button and the report displays a parameter
> query for the information that wasn't included by the form. I want the
> cancel button to close the form and report and go back to the
> switchboard menu. How can I fix this?
>
If I understand you correctly, you can do something like
Docmd.Close acReport, "MyReport"
Docmd.Close acForm, "MyForm"