OFF97: Errors Starting Visual Basic Editor

ID: Q162053


The information in this article applies to:
  • Microsoft Office 97 for Windows
  • Microsoft PowerPoint 97 For Windows
  • Microsoft Word 97 for Windows


SYMPTOMS

When you attempt to start the Visual Basic Editor, one or more of the following error messages may appear:

Could not open macro storage.


-or-

The Visual Basic Environment could not be initialized. Please run Setup to install it correctly.


-or-

<Application> could not fire event.

For example: Word could not fire event.


CAUSE

Possible causes for these errors are:

  • Insufficient disk space or low memory. (This is the most common cause.)


  • A damaged Word default template (Normal.dot) file.


  • A damaged Word document.


  • A wrong version for the Vbe.dll file.


  • A network rights (permissions) issue, if the Temp directory is on a server.



RESOLUTION

To prevent these errors from occurring, perform the following methods as appropriate:

Method 1: Rename the Default Word Normal Template

If this problem occurs with every document you open or create based on the Normal template, use the following steps to correct this problem:
  1. If you are working in Word, close Word.


  2. Find the Normal file. The default location is:


  3. <Drive>\Program Files\Microsoft Office\Templates
  4. Click to select Normal.dot.


  5. Type a new name; for example, Normal Old.dot.


After you perform this method, if the error continues, perform steps 1-4 again to rename Normal Old.dot back to Normal.dot.

Method 2: Create a New Document

If this problem occurs only with a particular document and does not occur with other documents, use the following steps to correct this problem:
  1. In a blank Word document, click File on the Insert menu.


  2. Click to select the document that was causing the error to occur and then click Insert.


  3. On the File menu, click Save.


  4. Type in a new file name for your document and then click Save.


NOTE: After your new document has been saved, you can delete the old document that was causing the problem.

Method 3: Rename and Reinstall the Vbe.dll File

For a corrupt, missing, or wrong version of the Vbe.dll file, perform the following steps:
  1. Quit all currently open applications.


  2. Start an MS-DOS prompt in a window. To do this, on the Windows taskbar, click Start, point to Programs, and then click MS-DOS Prompt.


  3. Change the directory to the location of the Vbe.dll file by typing the following and then pressing ENTER:
    CD C:\progra~1\common~1\micros~1\vba
    NOTE: This is the default directory for the Vbe.dll file. If you have installed Microsoft Office into another drive or directory, you need to type its path.


  4. Unregister the Vbe.dll file by typing the following:
    C:\Windows\System\REGSVR32 /U VBE.DLL
    NOTE: This is the default directory for the Windows System directory. If you have installed Windows into another directory, you need to type its path.


  5. Press ALT+TAB to minimize the MS-DOS Prompt window.


  6. Start Windows Explorer and rename Vbe.dll to Vbe.old.



  7. NOTE: The default installation folder for Vbe.dll is:
    C:\Program Files\Common files\Microsoft Shared\VBA
  8. In Windows Explorer, copy the file Vbe.dll from the Microsoft Office CD, found in the folder of:


  9. <CDROM drive:>\OS\System\VBE.dll
    to the following folder on your hard disk:
    C:\Program Files\Common files\Microsoft Shared\VBA
    NOTE: This is the default directory for the Vbe.dll file. If you have installed Microsoft Office into another drive or directory, you need to copy to that path.

  10. Maximize the MS-DOS Prompt window.


  11. In the MS-DOS Prompt window, make sure the current directory is


  12. C:\Program Files\Common files\Microsoft Shared\VBA
    or change the directory to the location of the Vbe.dll file by typing the following and then pressing ENTER:
    CD C:\progra~1\common~1\micros~1\vba
    NOTE: This is the default directory for the Vbe.dll file. If you have installed Microsoft Office into another drive or directory, you need to type its path and then re-register the Vbe.dll file by typing the following and then pressing ENTER:
    C:\Windows\System\REGSVR32 VBE.DLL
  13. Quit the MS-DOS Prompt window.


Network permissions of Create are necessary. (The Visual Basic Editor creates a folder in the Temp directory to store files.)

Method 4: Insufficient Disk Space or Low Memory

  • Add more RAM to your computer.

    NOTE: As a short-term solution, you can free RAM by shutting down unneeded programs.


  • Acquire more hard disk space (either by adding a larger disk drive or by freeing disk space by removing unneeded files).


  • Restart Windows.


  • Uninstall and reinstall Microsoft Office 97.


Method 5: Check Network Permissions

The Visual Basic Editor creates a folder in the Temp directory to store files. If the Temp directory is being accessed via a network share, the network permissions for this folder must have Create permissions. See your network administrator for information about setting permissions.

For additional information about the folder the Visual Basic Editor creates, click the article number below to view the article) in the Microsoft Knowledge Base:
Q158875 OFF97: .Exd Files Are Created When You Insert Controls


REFERENCES

For additional information about getting help with Visual Basic for Applications, click the article number below to view the article in the Microsoft Knowledge Base:

Q163435 VBA: Programming Resources for Visual Basic for Applications

Additional query words: wordcon off97 wd97 vba

Keywords : kbdta kbdtacode OffVBA word8 kbwordvba word97 vbe xlvbainf
Version : WINDOWS:97
Platform : WINDOWS
Issue type : kbprb


Last Reviewed: November 11, 1999
© 2000 Microsoft Corporation. All rights reserved. Terms of Use.