Cancel = True - error

  • Thread starter Thread starter PayeDoc
  • Start date Start date
P

PayeDoc

Hello All

I have a number of reports where I have set the OnNoData event to Cancel =
True. This works fine where the user attempts to open one of the report
usign a button created with the wizard for that purpose, but if they click a
button where the OnClick event includes lots of DoCmd OpenReport commands,
when the code reaches a report with no data they get a message that the
OpenReport was cancelled - and the code stops.

What do I do?
Hope someone can help

Many thanks
Leslie Isaacs
 
Do you have error handling in your code? IF so, does it use Resume Next?

We can't see the code you are using unless you post it and therefore it is
difficult to make suggestions to overcome the problem.

John Spencer
Access MVP 2002-2005, 2007-2010
The Hilltop Institute
University of Maryland Baltimore County
 
John

Many thanks for your reply - and apologies for the delay in my responding, I
had to be away unexpectedly.

I didn't have error handling, but now I do!!
I suddenly remembered that this was about handling error 2501, which I have
now done.

Thanks again
Les
 
Back
Top