troubleshooting Question

Using CommandBars ("Tools") in distributed .mde

Avatar of Denys
Denys asked on
Microsoft AccessVBA
13 Comments2 Solutions60 ViewsLast Modified:
I have written an Access 97 application as an extension to a legacy Access 97 .mde for which we have no source code, running under Windows 7. Ideally, I want to be able to relink the tables when the "extension" .mde is placed alongside the "legacy" on the Windows 7 target machine.  I have created a form button "Re-link the tables" which works fine on my development environment (XP in VMWare on a Mac) where I have a full Access 97 licence, but does not work  when run using the system.dsw Access runtime on the target machine.

The current workaround is to "prelink" the tables so that the "extension" .mde already contains the correct references, but I want to allow the user to relink to other folders containing alternate sets of data.

The form button runs the VBA code statement:

   CommandBars("Tools").Controls("&Add-Ins").Controls("&Linked Table Manager").Execute

But under Windows 7 the .mde does not carry the toolbar which runs the Linked Table Manager, so it just gives an illegal function error message, although it runs perfectly in the development environment.

Any suggestions on how to get around this?
ASKER CERTIFIED SOLUTION
Join our community to see this answer!
Unlock 2 Answers and 13 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 2 Answers and 13 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros