Extensive right-click menus (1 Viewer)

pdanes

Registered User.
Local time
Today, 01:19
Joined
Apr 12, 2011
Messages
105
I have an Access database that makes extensive use of right-click menus. 14 textboxes and comboboxes have a right-click menu attached, and they all work pretty well, most of the time. They are geared to the contents of the database, and so my code changes them when certain values in the database change. They are quite complex, a few of them are nested up to three levels deep with total choices in the thousands.

Over time, the db has become quite slow to open. Not the form that uses the menus, that opens in around a second, but the initial loading of the database into memory, as Access opens. In the registry under

HKEY_USERS\S-1-5-21-1393566959-1768521432-1143527593-1000\Software\Microsoft\Office\11.0\Access\Settings\CommandBars

I have found an enormous number of entries (almost nine thousand) named "ACBVlastni nabidka nnnnnnn", which is Czech for "ABCCustom menu" followed by a 7-digit number. These same items are visible in the custom menu/toolbar dialog box, under properties, except without the leading "ABC". When I close the problem DB and open a normal one, this list of thousands is not visible. In the immediate window, the command "?Application.CommandBars.Count" gives only around 190, regardless of whether executed in the bloated DB or a normal one.

I tried manually changing all the custom right-click menus back to toolbars and removing them - no change. I compacted and repaired the DB after removing - no change. I manually removed all these entries from the registry - no change. They're still visible in the custom menu/toolbar dialog box, even though they're not in the registry any more and the DB is still slow to load.

Does anyone know anything more about the use of right-click menus? Is this maybe one of those cases where something theoretically works, but was intended for much less massive application (a few fixed choices, instead of thousands and constantly changing)? I'd hate to give up these RC menus, they're incredibly useful and the user (only one) loves them, in spite of the startup delay. Does constantly changing them cause some sort of buildup, like the total number of controls that can be added to a form over its life? Would recreating a new database help? I've tried making a new one and importing everything. It all works fine until I check the "Import menus and toolbars" checkbox. That brings in the thousand of custom menus and the slowdown starts again.
 

Users who are viewing this thread

Top Bottom