Cannot Open Any More Databases - Subreport Issue

  • Thread starter Thread starter Sandy
  • Start date Start date
S

Sandy

Good afternoon.

I have a report with 10 subreports in it. I can view the
report just fine, however, when I try to print it I get
the error "Cannot open any more databases". When I remove
the last two subreports I do not get this error.

I looked up in help and don't see that there is a
subreport limit.

Any help would be much appreciated.. this report did work
in Access 2000.

Thanks!

Sandy S.
Database Coordinator
 
Hi.

Subreports are not the limit that you are running up against for this error.
It's most likely linked tables that the report and these subreports are
using that are causing the problem.

Error #3048 is usually caused by your database application trying to handle
too many tables at the same time. There are 2048 "table handles," or
TableID's, available for Jet 3.51 and 4.0 (1024 TableID's for Jet 3.0 and
3.5) that Access requires when dealing with each table or linked table.

TableID's are used for the following:

- Tables
- Queries
- Bound forms and reports
- Modules for forms and reports
- Combo boxes and list boxes whose row source is a table or query
- Data Access Objects (DAO) Recordsets in code
- Domain functions, such as DLookup( ), DCount( ), et cetera.

If this error is caused by the application using too many TableID's, then
ensure that every Recordset used in code is explicitly closed and the
Recordset variable set to Nothing before the variable goes out of scope. If
this is occurring only after the report is opened multiple times, then
you'll likely fix the problem by explicitly closing and setting objects to
Nothing in at least one code module.

If this isn't enough to prevent the error message from recurring, then the
alternatives are to reduce the number of combo boxes that meet the above
listed criteria, simplify complex queries, or to unlink some of the tables
(linked tables require twice as many TableID's) and place these tables in
the database file.

Reducing the number of any of the items on the list above will help reduce
the number of TableID's in use. The important thing to remember is the
total number of TableID's in use at the same time needs to be prevented from
exceeding the limit.

This error has also been reported to be caused by implicitly referring to
the value of a checkbox in an If...Then block statement. If this is the
case, then the solution is to explictly refer to this value, instead.

HTH.

Gunny

See http://www.QBuilt.com for all your database needs.
See http://www.Access.QBuilt.com for Microsoft Access tips.

(Please remove ZERO_SPAM from my reply E-mail address, so that a message
will be forwarded to me.)
 
Gunny,

Thank you!

I appreciate your quick response and have already
employed this type of solution and it has worked nicely.

I will pass this information along to my co-workers as
well..

Good to know!

Thanks,

Sandy S.
 
Hi,

I have posted the same Problem on 9/30/2004 and it is still not solved.

Thank you for your answer to Sandy, which is about the best I've read in the
hole Web until now. I have two questions:

1. Is it possible to display the number of used table-handles ?

2. What you mean by implicitly referring to the value of a checkbox ? Use
the boolean variable instead of the name of the checkbox in the form or the
other way round ? Or not using boolean variables of the type "Yes/No" in the
definition of tables and queries?

Thank you for your help, which I really appreciate.

Fred Wing
 
Back
Top