XL5 Err Msg: "Can't Find Project or Library" Running Macro

ID: Q124277

The information in this article applies to:

SUMMARY

In Microsoft Excel 5.0, you may receive the following error message when you attempt to run a Visual Basic macro:

   Can't Find Project or Library

RESOLUTION

To correct the referencing problem, follow these steps:

1. In the References dialog box, click Browse.

2. Select the correct path and name of the file you want to

   reference and click OK.

   The new file name, with the correct path shown at the bottom, should
   appear in the References dialog box.

3. Click OK and save the file.

You should be able to run the macro once the references have been set to the correct files.

MORE INFORMATION

In Microsoft Excel version 5.0, in order to use external or custom functions from another library or workbook, you must establish a reference to the file through the References option on the Tools menu. The References option allows you to add, delete, or make available for editing Visual Basic references to libraries or other workbooks that are specified for the active workbook. You must be in a Visual Basic module to use this command.

If you try to run a Visual Basic macro that has a reference to a file or library, and the file or library does not exist in the specified location, you will receive the error message above. To check the location of any references your workbook may have, follow the steps below:

1. On the Tools menu, click References.

2. Select any reference listed in the Available References list.

The path to the file will be displayed in the Group box at the bottom of the References dialog box.

REFERENCES

"Visual Basic User's Guide," version 5.0, chapter 4, "Organizing Procedures and Modules in Workbooks"

For more information about the Reference command, choose the Search button in Help and type:

   Reference command (Tools menu)

Additional query words: 7.00 5.00
Keywords          : kbcode kberrmsg
Version           : WINDOWS: 5.0, 5.0c, 7.0; MACINTOSH: 5.0, 5.0a
Platform          : MACINTOSH WINDOWS

Last Reviewed: February 4, 1998