Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Reference to MAPI, or reference to any library

Status
Not open for further replies.

BruceWMoore

Programmer
Jun 29, 2003
6
US
In thread705-1577931, trevorwilliams2 is asking about how to set up a new reference, in an effort to solve an issue where libraries referred to in references are not available in various environments. It does not seem to me that he got a really satisfactory answer.

Meanwhile, I had run into and overcome a very similar problem. We had written a custom library for our ADEs, to act as a central repository of our code.

I had researched this off and on for months, and finally came across an obscure post describing a way to handle it. I have implemented this, and placed a complete description of how I did it on my web site.

I call it the "lost folder" method. The way Windows works, anytime a reference is missing, it will look first in the current folder, and then in the folders in the path to try to resolve the reference. This behavior only kicks in if the reference is not found.

What I wanted to have happen was to have MS Access look in the current folder, and resolve the reference. I didn't want it to ever refer back to the original location of the procedure library, because that would tie up the master copy of it, making it difficult to put in new versions, etc. In our environment, a separate copy of the front end is always run on the local user's machine.

The answer was to create a situation where the procedure library was not ever found in the location where it was originally compiled and referred to. Hence, my "lost folder" method. This ensures that MS Access will always search for the library reference at run time, and if we make sure that the library in question is always present in the folder where the application is running, then it will always be found. No more problem with a missing reference.

I think that perhaps Trevor could have used my method to solve his problem with the MAPI library being in various different places for different environments.

For more details, see
Bruce W. Moore
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top