Developing for Dynamics GP

by Microsoft Dynamics GP Developer Support Team (Fargo, ND, USA)

File not found: VBA6.dll error occurs or GP crashes

File not found: VBA6.dll error occurs or GP crashes

  • Comments 10

Beth Gardner - Click for blog homepageThis is a follow up to my previous post on the VBA6.dll not found error (for 64-bit). I have found this can occur on 32-bit computers and Microsoft Dynamics GP 10.0 and GP 2010.

[Edit] Re-installing the VBA 6.4 core components (as used by Dynamics GP) has been shown to resolve this issue for VBA6.DLL, VBE.DLL, VBA7.DLL and VBE7.DLL errors.  Please download the necessary files from this link:

 

[Edit 2] If installing the VBA Components does not resolve the issue try the steps below to unregister the msvbvm60.dll file:

  1. Log in to Microsoft Dynamics GP as 'sa', go to the Customization Maintenance window and export everything into a package file.
     
  2. Log out of Dynamics GP and then in the Dynamics GP code directory, move all of the .VBA files out into a backup directory as well as any forms and report dictionary files, such as Forms.dic and Reports.dic.
     
  3. Un-register the 'MSVBVM60.DLL file:
            • For a 64-bit Operating System: Go to Start > Run and enter in:
                        regsvr32.exe c:\windows\syswow64\msvbvm60.dll /u
            • For a 32-bit Operating System: Go to Start > Run and enter in:
                        regsvr32.exe c:\windows\system32\msvbvm60.dll /u
     
  4. Log back into Dynamics GP again as 'sa', go back into the Customization Maintenance window and import the package file from step 1 back into Dynamics GP, this will re-create the VBA files and forms and report dictionary files.
     
  5. Try having users login again to Dynamics GP to see if the same VBA6.dll or VBA7.dll error shows.

 

Important: This post contains information about how to modify the registry. Make sure that you back up the registry before you modify it. Make sure that you know how to restore the registry if a problem occurs. For more information about how to back up, restore, and modify the registry, click the following article number to view the article in the Microsoft Knowledge Base (KB) Article:

I have found that the issue is because the 4.0 registry key is missing.  This is created with earlier versions of Microsoft Office and Microsoft Dynamics GP.

To resolve this error, you need to add the 4.0 registry key. 

Here are the steps:

  1. Make a full backup of the system registry.
     
  2. Export all modifications to a .package file from Microsoft Dynamics GP under Tools | Customize | Customization Maintenance.
     
  3. Create a .reg file that contained the following in Notepad:
     
    Windows Registry Editor Version 5.00
     
    [HKEY_CLASSES_ROOT\TypeLib\{000204EF-0000-0000-C000-000000000046}\4.0]
     
    @="Visual Basic For Applications"
     
    [HKEY_CLASSES_ROOT\TypeLib\{000204EF-0000-0000-C000-000000000046}\4.0\9] 
     
    [HKEY_CLASSES_ROOT\TypeLib\{000204EF-0000-0000-C000-000000000046}\4.0\9\win32] 
     
    @="C:\\Program Files\\Common Files\\Microsoft Shared\\VBA\\VBA6\\VBE6.DLL"
     
    [HKEY_CLASSES_ROOT\TypeLib\{000204EF-0000-0000-C000-000000000046}\4.0\FLAGS] 
     
    @="0"
     
    [HKEY_CLASSES_ROOT\TypeLib\{000204EF-0000-0000-C000-000000000046}\4.0\HELPDIR] 
     
    @="C:\\Program Files\\Common Files\\Microsoft Shared\\VBA\\VBA6\\"
     
  4. Next, double-clicked the .reg file, so it was added to the system registry. 
     
  5. The HKEY_CLASSES_ROOT\TypeLib\{000204EF-0000-0000-C000-000000000046}\4.1 key should point to the VBE7.dll file.
     
  6. Next delete the .vba files that were 4kb and renamed the .vba files that were over 4kb in the Microsoft Dynamics GP code folder.
     
  7. Start Microsoft Dynamics GP.  You should not receive any errors.
     
  8. Import the .package file.  Verify the code works and the error no longer occurs.

I have had a few customers state that they had to unregister the msvbvm60.dll.  But I did not run across that with the customers I have streamed in with.

Beth Gardner

Support Escalation Engineer
Microsoft Dynamics GP Developer Support

16-Nov-2010: Added link to previous article.

14-Mar-2011: Added link to VBA 6.4 core components (English only) which can be used to resolve this issue.

29-Oct-2012: Added some more terms for search: VBA.DLL, VBE.DLL, VBA6.DLL, VBE6.DLL, VBA7.DLL, VBE7.DLL.

05-Aug-2013: Updated fix information to clarify that Dynamics GP using VBA v6, even though the error might be for VBA v7.

09-Sep-2013: Added additional steps to unregister msvbvm60.dll if needed.

Page 1 of 1 (10 items)
Comments Information

PLEASE READ BEFORE POSTING

Please only post comments relating to the topic of this page.

If you wish to ask a technical question, please use the links in the links section (scroll down, on right hand side) to ask on the Newsgroups or Forums. If you ask on the Newsgroups or Forums, others in the community can respond and the answers are available for everyone in the future.

Leave a Comment
  • Please add 4 and 8 and type the answer here:
  • Post