The error is usually generated by the call that opens the report, such as
DoCmd.OpenReport in the Click event of a button. One common occurrence for
this would be if you had code in the NoData event of the report to close the
report if there is nothing for it to do. The error can usually just be
trapped and ignored in your error handler if everything else is working
properly. However, you may want to step through your code first to make
sure.
The most common problem when going from Access 97 to 2000 or newer is that
2000 or newer uses ADO by default instead of DAO. Both of these object
models of components with the same names, such as Recordset. If your DIM
statements just say "Dim rst As Recordset", Access is probably trying to
create an ADO recordset for you and this may be causing problems with the
results being returned. You'll need to make sure that DAO is checked in the
References. (In the code editor go to Tools|References and make sure there
is a check next to "Microsoft DAO 3.6 Object Library". If there is an
earlier version checked, uncheck it and check the newer one.) Next,
explicitly define with object model to use in your DIM statements by
changing "As Recordset" to "As DAO.Recordset". Do this for all DAO objects
(querydefs, fields, database, etc). Edit|Replace (Ctrl+H) usually works well
for this.