XL5: "File Not Found" Error Using References Dialog Box

ID: Q120404


The information in this article applies to:


IMPORTANT: This article contains information about editing the registry. Before you edit the registry, make sure you understand how to restore it if a problem occurs. For information about how to do this, view the "Restoring the Registry" Help topic in Regedit.exe or the "Restoring a Registry Key" Help topic in Regedt32.exe.

SYMPTOMS

In a Visual Basic for Applications module, if you click References on the Tools menu, you may receive the following error message:

File Not Found
When you attempt to open a workbook that contains a module sheet in Microsoft Excel, you may receive the following error message:
Error 48: Error in loading DLL
When you start Microsoft Excel, you may receive the following error message:
An Excel lexicon, Xlen50.olb, is missing or damaged.


CAUSE

This problem occurs when the following conditions are true:

The symptoms may also occur if the file Stdole.tlb cannot be located. For additional information, please see the following article in the Microsoft Knowledge Base:
Q124596 Errors Creating New Macro or Module Sheet


WORKAROUND

To work around this problem, copy the Xlen50.olb, Vbaen.olb and Stdole.tlb files to the appropriate local locations on your computer. For example, copy these files to the following locations.


   File           Folder
   -----------------------------

   Xlen50.olb     Excel
   Vbaen.olb      Windows\System
   Stdole.tlb     Windows\System 

After you copy the files locally, use the appropriate following procedure.

WARNING: Using Registry Editor incorrectly can cause serious problems that may require you to reinstall your operating system. Microsoft cannot guarantee that problems resulting from the incorrect use of Registry Editor can be solved. Use Registry Editor at your own risk.

For information about how to edit the registry, view the "Changing Keys And Values" Help topic in Registry Editor (Regedit.exe) or the "Add and Delete Information in the Registry" and "Edit Registry Data" Help topics in Regedt32.exe. Note that you should back up the registry before you edit it. If you are running Windows NT, you should also update your Emergency Repair Disk (ERD).

Microsoft Excel or Microsoft Project Under Microsoft Windows 3.x:

To edit the Reg.dat file to point to new locations, follow these steps:
  1. In Program Manager, click Run on the File menu.


  2. In the command line box, type regedit /v.


  3. Click Find Key on the Registration Info Editor Search menu. In the Find What box, type typelib, and click the Find Next button.

    This search process should take you to a location labeled
    
          TypeLib = OLE (Part 4 of 5) 


  4. Locate the "1.0 = Visual Basic for Applications" line. Below this line there should be a line resembling the following:
    
          win16 = \\Server\Share\Directory(s)\XLEN50.OLB 

    NOTE: You may see a double backslash in the middle of the entry, for example Server\Share\\Directory\XLEN50.OLB. This is an indication that the system is not properly using the UNC name.


  5. Select the entry and edit the text in the Value box to reflect the new location of Xlen50.olb, for example:
    
          C:\Excel\Xlen50.olb. 


  6. On the File menu, click Exit. Click Yes to save the changes.


  7. Repeat steps 1-6 for Vbaen.olb and Stdole.tlb to modify the registration database (Reg.dat) to point to their new locations.


  8. Restart Microsoft Windows.


Microsoft Excel or Microsoft Project Under Microsoft Windows NT 3.51:

To edit the registry to point to new locations, following these steps:
  1. In Program Manager, click Run on the File menu.


  2. In the command line box, type regedit /v. Click OK.


  3. On the Search menu, click Find Key.


  4. Type the following in the Find What box
    
          \TypeLib\{000204F3-0000-0000-C000-000000000046}\1.0\9\Win16 

    and then click Find Key.


  5. Modify the value of this key to use the new path of Vbaen.olb (the value box is at the top of the window below the menu bar) and press ENTER.


  6. On the Search menu, click Find Key.


  7. Type the following in the Find What box
    
          \TypeLib\{00020813-0000-0000-C000-000000000046}\1.0\9\Win16 

    and click Find Key.


  8. Modify the value of this key to use the new path of Xlen50.olb (the value box is at the top of the window below the menu bar) and press ENTER.


  9. On the File menu, click Exit. Click Yes to save changes.


  10. Restart Windows.


Use similar steps to modify the Stdole.tlb keys. The Stdole.tlb keys can be found by searching for the following keys:

   \TypeLib\{00020430-0000-0000-C000-000000000046}\1.0\9\Win16
   \TypeLib\{00020430-0000-0000-C000-000000000046}\1.0\0\Win16 

Microsoft Excel or Microsoft Project Under Windows 95 or Windows NT 4.0:

To edit the registry to point to new locations, following these steps:
  1. On the Start menu, click Run.


  2. Type regedit, and click OK.


  3. In the Registry window, click the plus sign (+) to the left of the following keys, in order
    
           HKEY_CLASSES_ROOT
           TypeLib
           {000204F3-0000-0000-C000-000000000046}
           1.0
           9 

    to open the following registry key:
    
           My Computer\HKEY_CLASSES_ROOT\TypeLib\{000204F3-0000-0000-C000-
           000000000046}\1.0\9 

    Then, click the folder to the left of Win16. The following key appears in the status bar:
    
           My Computer\HKEY_CLASSES_ROOT\TypeLib\{000204F3-0000-0000-C000-
           000000000046}\1.0\9\Win16 


  4. Click the entry for Vbaen.olb.


  5. On the Edit menu, click Modify.


  6. Change the Value Data to the new path for Vbaen.olb and click OK.


  7. In the Registry window, click the plus sign (+) to the left of the following keys, in order
    
           HKEY_CLASSES_ROOT
           TypeLib
           {00020813-0000-0000-C000-000000000046}
           1.0
           9 

    to open the following registry key:
    
           My Computer\HKEY_CLASSES_ROOT\TypeLib\{00020813-0000-0000-C000-
           000000000046}\1.0\9 

    Then, click the folder to the left of Win16. The following key appears in the status bar:
    
           My Computer\HKEY_CLASSES_ROOT\TypeLib\{00020813-0000-0000-C000-
           000000000046}\1.0\9\Win16 


  8. Click the entry for Xlen50.olb.


  9. On the Edit menu, click Modify.


  10. Change the Value Data to the new path for Xlen50.olb and click OK.


  11. Repeat steps 310 using the following registry keys:
    
           HKEY_LOCAL_MACHINE\SOFTWARE\Classes\TypeLib\{000204F3-0000-0000-
           C000-000000000046}\1.0\9
    
           HKEY_LOCAL_MACHINE\SOFTWARE\Classes\TypeLib\{00020813-0000-0000-
           C000-000000000046}\1.0\9 


  12. On the Registry menu, click Exit.


  13. Restart Windows.


Microsoft Excel for Windows NT:

Use the method that corresponds with the version of Windows that you are running and use the criteria in the following table.

   Replace This file   With This File
   ----------------------------------

   Win16               Win32
   Xlen50.olb          Xlen32.olb
   Vbaen.olb           Vbaen32.olb
   Stdole.tlb          Stdole32.tlb 

If you are a network administrator, you may want to use a batch procedure to work around this problem. For more information, please see the following article in the Microsoft Knowledge Base:
Q129422 XL5: Network Admin Method for Updating Registration Database


STATUS

Microsoft has confirmed this to be a problem in the Microsoft products listed at the beginning of this article.


MORE INFORMATION

When you perform a workstation installation of Microsoft Excel 5.0, most of the program files are run from the server, including Xlen50.olb and Vbaen.olb, the Microsoft Excel and Visual Basic for Applications, object library files. By default, these files are listed in the References dialog box as available object libraries. However, when you use the References dialog box in a Visual Basic module as described in this section, and the server uses the universal naming convention (UNC), Microsoft Excel cannot locate these files.

You can use the References dialog box to create a link to another project (for example, a workbook that contains a Visual Basic module) from the active project. When you reference another project, you can call any Sub or Function procedure within that project without opening the workbook or using the name of the module that contains the Sub or Function.


REFERENCES

For more information about referenced projects, click the Search button in the Visual Basic Reference and type:

referenced project

Additional query words: network lanman novell


Keywords          : kberrmsg kbprg 
Version           : WINDOWS:4.0,5.0,5.0c; winnt:5.0
Platform          : WINDOWS winnt 
Issue type        : kbprb 

Last Reviewed: April 27, 1999