Solved

Visual Basic module reports cant find project or library for Trim on autoexec

Posted on 2001-07-31
6
369 Views
Last Modified: 2008-03-17
Im using Access 2000 and trying to fix a problem in a function called during autoexec.

The function uses Trim and throws the error "cant find project or library". Which seems fairly silly. Is this a known problem? can anyone offer any suggestions.

This isnt my database so I dont have a complete history of its development. Trim and Left etc. all work once the database has started.
0
Comment
Question by:frankhampshire
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
6 Comments
 

Author Comment

by:frankhampshire
ID: 6338848
Update: None of the string functions such as Left, Right, Trim Ltrim Rtrim seem to be working. Strangely, Len is.
0
 
LVL 14

Accepted Solution

by:
mgrattan earned 100 total points
ID: 6338881
Check for "MISSING" indicator in Tools/References while any code module is open.  Unchecking the MISSING item and then adding it back will usually fix the problem.  The problem is caused, typically, by a DLL/OCX that is of a different version than the one used on the development machine.
0
 
LVL 14

Expert Comment

by:mgrattan
ID: 6338884
Also, if any of those functions are being used in a VBA routine, you can force them to work by explicitly calling them from the VBA object:

VBA.Left()
VBA.Right()

etc.
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 54

Expert Comment

by:nico5038
ID: 6338907
Just a small addition, access will add libraries when you add a new item from the toolbox. When you remove that item (often an .ocx), access leaves the library checked...
This will normally cause no problems, until you move the application to another computer or remove some "obsolete" .ocx files.

Personally I remove all checked libraries one by one and run a "compile all modules" after each uncheck to see or everything still works. If not, I just check that library again...

Nic;o)
0
 

Author Comment

by:frankhampshire
ID: 6338925
mgrattan. Thanks Heaps. This was right on the money. Take these points, but dont spend 'em all in once place ;-)
0
 
LVL 14

Expert Comment

by:mgrattan
ID: 6341170
Thanks, glad I could help.

ps:  I *wish* I could spend those points! ;-)
0

Featured Post

Salesforce Has Never Been Easier

Improve and reinforce salesforce training & adoption using WalkMe's digital adoption platform. Start saving on costly employee training by creating fast intuitive Walk-Thrus for Salesforce. Claim your Free Account Now

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Overview: This article:       (a) explains one principle method to cross-reference invoice items in Quickbooks®       (b) explores the reasons one might need to cross-reference invoice items       (c) provides a sample process for creating a M…
This article describes two methods for creating a combo box that can be used to add new items to the row source -- one for simple lookup tables, and one for a more complex row source where the new item needs data for several fields.
Basics of query design. Shows you how to construct a simple query by adding tables, perform joins, defining output columns, perform sorting, and apply criteria.
In Microsoft Access, learn different ways of passing a string value within a string argument. Also learn what a “Type Mis-match” error is about.

737 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question