Unable to load DLL VistaDb20.dll because of an invalid access to memory location (HRESULT: 0x800703E6)


I have a project that was built in Visual Studio 2005 in C#. I created an installer for the Windows application (in VS2010) and it installs and works fine on Windows XP SP3. I tried installing it on Windows 7 32-bit and it says installation is successful but when I try to open the application I receive this error message:

A fatal error has occurred. Unable to load DLL 'VistaDb20.dll': Invalid access to memory location. (Exception from HRESULT: 0x800703E6)

People suggested I run this in the command line: regsvr32 VistaDb20.dll

I get the error message:

The module "VistaDb20.dll" was loaded but the entry-point DllRegisterServer was not found. Make sure that "VistaDb20.dll" is a valid DLL or OCX file and then try again.

So then I tried regasm VistaDb20.dll /tlb:VistaDb20.tlb using the .NET Framework Assembly Registration Utility 2.0.50727.4927 and get error:

RegAsm : error RA0000 : Failed to load 'VistaDb20.dll' because it is not a valid .NET assembly.

I am not sure how to get my application running on Windows 7 with this .dll problem. Any help would be appreciated. This application and the database was created using VistaDB 2.1

I guess I can't change the actual dll since I did not create it but maybe I have to change some properties of the dll in Visual Studio?

asked on Stack Overflow Mar 7, 2012 by tennisbuddy • edited Mar 8, 2012 by Jens Bj├Ârnhager

2 Answers


According to this your problem is that this DLL is not compatible with DEP. You'll need to disable DEP to workaround this but in the long term you should try to wean yourself off this particular dependency.

answered on Stack Overflow Mar 8, 2012 by David Heffernan

I had this error while trying to registering my VB .NET assembly using RegAsm command:

RegAsm : error RA0000 : Failed to load 'VistaDb20.dll' because it is not a valid .NET assembly.

I solved the problem buy executing RegAsm of the right .NET Framework.

I mean you should use the tools of the same Framework that you make as target in your advanced options of compilation (VS2010).

answered on Stack Overflow Aug 9, 2012 by Tamer.bak • edited Aug 9, 2012 by j0k

User contributions licensed under CC BY-SA 3.0