-1

Could not load file or assembly 'System.Data.SQLite, Version=1.0.66.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139' or one of its dependencies. An attempt was made to load a program with an incorrect format.

connection string am using

 SQLiteConnection con = new SQLiteConnection("Data Source=F:\\Game\\GameBKS\\Game_Latest\\GameNew\\exe.BKS.s3db;Version=3;FailIfMissing=false;New=True;Compress=True;Synchronous=Off");
C.Evenhuis
  • 24,516
  • 2
  • 54
  • 68

1 Answers1

0

The SQLite library contains/interacts with (depending on which version you are using) a native SQLite library, and these are platform-specific.

The message below indicates that the library is incompatible with the mode your application is currently running in:

An attempt was made to load a program with an incorrect format.

You can change the target platform in the project properties -> build -> platform target combobox. If you downloaded the x86 version of the library, your project must also be compiled for x86 specifically.

C.Evenhuis
  • 24,516
  • 2
  • 54
  • 68