Library Not Registered Error

Written by Allen Wyatt (last updated March 23, 2021)
This tip applies to Excel 97, 2000, 2002, and 2003


1

When you start Excel, it goes through quite a few procedures to make sure that everything is running properly. If it detects an error, you may see an error message in a dialog box. Sometimes the messages you see in the dialog box are not that clear, and a few are downright cryptic.

For instance, you may see a message that says "object library not registered," and be completely lost as to what it means. In this case, it is helpful to understand how Excel works with external programs.

During part of the startup process, Excel may load any number of add-ins that provide additional functionality to your copy of Excel. Basically, these add-ins are collections of macros that perform certain tasks. Macros, in turn, can rely upon other files that contain information that helps them perform their duties. These external files are called libraries.

Excel comes with an amazing number of libraries, but not all of them are accessible at the same time. A library is only available after it has been "registered" with Excel. If the library is not registered, then Excel cannot use it and the macros in the add-in cannot use it. The result: an error message.

The best way to troubleshoot this problem is for you to determine what add-ins are being loaded when you start Excel. Examine your Excel Startup folder, and make sure you know what they are all doing. (You don't need to know what they are doing, step by step, but you should be familiar with what the add-in does, in general.)

Next, find another system that loads the same add-ins. (This should be easy to do if you work in an office, but more difficult if you are a home user.) Once you find the similar system, make sure it starts up without problem. If it does, then on the problem-free system, do the following:

  1. Press Alt+F11 to display the VBA Editor.
  2. Choose References from the Tools menu. You see the References dialog box. (See Figure 1.)
  3. Figure 1. The References dialog box.

  4. Make note (on a piece of paper) of the names of the libraries that have check marks next to them. Write the exact names, as there could be many libraries with similar names. Also, all the selected libraries--those with check marks--should be listed at the top of the reference list.
  5. Close the References dialog box.
  6. Close the VBA Editor.

Now, on the system that has problems, do these same steps, except in Step 3 you need to make sure that the same libraries are selected as those you wrote down. When you close the VBA Editor, restart Excel to see if the problem is still there. If it is, or if you couldn't find one of the noted libraries on the problem system, then you may need to re-register Excel completely. If so, follow these steps:

  1. Make sure that Excel is not running (exit the program).
  2. Click the Start button to displays the Start menu.
  3. From the Start menu, choose Run. Windows displays the Run dialog box. (See Figure 2.)
  4. Figure 2. The Run dialog box.

  5. In the Open box, enter the full path name to your Excel program, followed by the /regserver switch. If the full path name includes spaces, surround the full path name by quote marks. The following is an example of what you can enter in the Open box (your path may be different):
  6.      "c:\Program Files\Microsoft Office\Office\Excel.exe" /regserver
    
  7. Click OK.

When you restart Excel, the problem should have disappeared. If it didn't, then you need to figure out exactly which add-in is causing the problem. You do this by locating the add-in files in the Startup folder, and renaming them or moving them to a temporary folder. Do this one file at a time, restarting Excel after each renaming or move. When the problem disappears, you know you found the problem add-in, and you can contact the vendor to find out how to resolve the problem.

Note:

If you would like to know how to use the macros described on this page (or on any other page on the ExcelTips sites), I've prepared a special page that includes helpful information. Click here to open that special page in a new browser tab.

ExcelTips is your source for cost-effective Microsoft Excel training. This tip (2952) applies to Microsoft Excel 97, 2000, 2002, and 2003.

Author Bio

Allen Wyatt

With more than 50 non-fiction books and numerous magazine articles to his credit, Allen Wyatt is an internationally recognized author. He is president of Sharon Parq Associates, a computer and publishing services company. ...

MORE FROM ALLEN

Swapping Two Numbers

When developing a macro, you may need to swap the values in two variables. It's simple to do using the technique in this tip.

Discover More

Making a Cell's Contents Italics within a Macro

You can use macros to process information in your worksheets. You may want to use that macro to apply the italic ...

Discover More

Word Count for a Portion of a Document

Word doesn't provide a field that allows you to return a word count for a portion of your document, but you can create ...

Discover More

Program Successfully in Excel! John Walkenbach's name is synonymous with excellence in deciphering complex technical topics. With this comprehensive guide, "Mr. Spreadsheet" shows how to maximize your Excel experience using professional spreadsheet application development tips from his own personal bookshelf. Check out Excel 2013 Power Programming with VBA today!

More ExcelTips (menu)

Maintaining the Active Cell

Move from one worksheet to another, and Excel selects whatever cell was last used in the worksheet you are selecting. If ...

Discover More

Displaying a Count of Zeros on the Status Bar

Excel allows you to display the results of several common worksheet functions on the status bar. The available functions ...

Discover More

Fixing "Can't Find Files" Errors

If you get errors about unfindable files when you first start Excel, it can be frustrating. Here's how to track down and ...

Discover More
Subscribe

FREE SERVICE: Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your address and click "Subscribe."

View most recent newsletter.

Comments

If you would like to add an image to your comment (not an avatar, but an image to help in making the point of your comment), include the characters [{fig}] (all 7 characters, in the sequence shown) in your comment text. You’ll be prompted to upload your image when you submit the comment. Maximum image size is 6Mpixels. Images larger than 600px wide or 1000px tall will be reduced. Up to three images may be included in a comment. All images are subject to review. Commenting privileges may be curtailed if inappropriate images are posted.

What is 1 + 1?

2017-04-26 11:38:48

Felix Munoz

Hi, I have this problem when I try to use an reference to Microsoft Project 15.0 Object Library in Excel. The same file MSPRJ.OLB is working great inside MSProject VBA Editor, but, when I try to use it on Excel, I get this error. It's possible to be an incompaltibility between my versions of Office and MSProject? Example:

MSProject.ActiveProject.Resources.Item(1).name works inside MSProject, but this command on Excel generates an error.

Thanks in advance for any help.

Regards
Felix Munoz


This Site

Got a version of Excel that uses the menu interface (Excel 97, Excel 2000, Excel 2002, or Excel 2003)? This site is for you! If you use a later version of Excel, visit our ExcelTips site focusing on the ribbon interface.

Newest Tips
Subscribe

FREE SERVICE: Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your address and click "Subscribe."

(Your e-mail address is not shared with anyone, ever.)

View the most recent newsletter.