Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.databases.ms-access > #10738

Re: Trap error 3048: cannot open any more databases

From "Phil" <phil@stantonfamily.co.uk>
Newsgroups comp.databases.ms-access
Subject Re: Trap error 3048: cannot open any more databases
Date 2015-05-18 22:50 +0100
Organization Aioe.org NNTP Server
Message-ID <mjdms2$jnl$1@speranza.aioe.org> (permalink)
References <78339dcc-c24a-46c6-b8a8-0e30bf39e9e9@googlegroups.com> <affbabce-0d75-49a3-bf3c-907ce9fe6f58@googlegroups.com>

Show all headers | View raw


On 18/05/2015 20:33:56, Patrick Finucane wrote:
> > On Monday, May 18, 2015 at 2:35:47 PM UTC-4, internet...@foobox.com wrote:
>> I have one database in which this error pops up more frequently than I would like.  
I know what it means and the users are very patient and simply close down
unwanted windows. They can then get on with what they are doing.
> > On Monday, May 18, 2015 at 2:35:47 PM UTC-4, internet...@foobox.com wrote:
>>
> > On Monday, May 18, 2015 at 2:35:47 PM UTC-4, internet...@foobox.com wrote:
>> What I was wondering though: is it possible to trap error 3048 in one place to 
cover all forms etc so that I can issue a more meaningful message?  
The standard one is not the most meaningful, even it is technically correct.
> On Monday, May 18, 2015 at 2:35:47 PM UTC-4, internet...@foobox.com wrote:
> 
> It seems, from what I've read, that this occurs when running code within a
> loop. Constantly opening/closing a recordset or db. It seems the solution
> is to come up with a method that opens the table once, not over and over.
> 
> Maybe google the words "access error 3048"
> 
> 

The wording “cannot open any more databases” is very confusing. 
In my experience, what it means is cannot open any more queries.
I have had this problem with a single form that had about 
20 continuous subforms and the subforms had combo boxes, 
obviously everything using queries as recordsources or 
Rowsources, and these queries often had subqueries. 
You get thepicture.

The main form had half a dozen tabs on it, 
and the problem was significantly improved by
opening the subforms on each tab, only when the tab was active,
and closing them when changing to a different tab.

There are people who advise after opening a recordset in VBA 
and after closing it, setting it to Nothing when you have finished with it. 
I always do so, but I have had contradictory advice whether it is necessary,
but it certainly won’t hurt.

Phil

---
This email has been checked for viruses by Avast antivirus software.
http://www.avast.com

Back to comp.databases.ms-access | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Trap error 3048: cannot open any more databases internet.shopping@foobox.com - 2015-05-18 11:35 -0700
  Re: Trap error 3048: cannot open any more databases Patrick Finucane <patrickfinucanetx@gmail.com> - 2015-05-18 12:33 -0700
    Re: Trap error 3048: cannot open any more databases "Phil" <phil@stantonfamily.co.uk> - 2015-05-18 22:50 +0100
      Re: Trap error 3048: cannot open any more databases internet.shopping@foobox.com - 2015-05-19 11:35 -0700
        Re: Trap error 3048: cannot open any more databases "Phil" <phil@stantonfamily.co.uk> - 2015-05-19 20:35 +0100

csiph-web