Could not load assembly


#1

I’ve tried multiple versions of the client dll, and keep getting this error. Anyone know why this is? My environment is VS2013 x64 Ultimate.

Could not load file or assembly ‘AerospikeClient’ or one of its dependencies. An attempt was made to load a program with an incorrect format.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.BadImageFormatException: Could not load file or assembly ‘AerospikeClient’ or one of its dependencies. An attempt was made to load a program with an incorrect format.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Assembly Load Trace: The following information can be helpful to determine why the assembly ‘AerospikeClient’ could not be loaded.


#2

Hi,

Have you already tried rebuilding Aerospike.sln after updating its platform to x64 via Build -> Configuration Manager as described here - http://www.aerospike.com/docs/client/csharp/install?


#3

Indeed I did. I got it working, I had to set the build to All CPU’s, but even then if i had the lua51.dll in my bin folder it would complain about that one. Removing that DLL and removing references to it worked.


#4

Great! That was going to be my next question and suggestion :slight_smile: