This thread looks to be a little on the old side and therefore may no longer be relevant. Please see if there is a newer thread on the subject and ensure you're using the most recent build of any software if your question regards a particular product.
This thread has been locked and is no longer accepting new posts, if you have a question regarding this topic please email us at support@mindscape.co.nz
|
Hello, when I try to access my SQLite DB in my very simple winforms app I'm getting this error: System.BadImageFormatException: Could not load file or assembly 'System.Data.SQLite, Version=1.0.62.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139' or one of its dependencies. An attempt was made to load a program with an incorrect format. when I want to add new row to DB. SQLite 1.0.62.0 provider is added to references from Lightspeed directory and I can update database tables using Lightspeed Designer. Any ideas what could be wrong? Thanks |
|
|
Hi Webio, Are you building on a 64 bit machine targeting AnyCPU? The SQLite assembly which we ship is a 32 bit version, so if you are compiling for 64 bit you will find that exception is thrown when the assembly is being attempted to be loaded. VS.net is a 32 bit app, so the problem doesnt show up there. If you need a 64 bit version of the assembly, you can download it from http://sqlite.phxsoftware.com/
Jeremy |
|
|
Thats it! Thanks |
|
|
Hello Jeremy, I'm getting the same error but I have a 32 bit processor. In an old post that now I'm unable to find, someone was talking about a license file. Do you have any idea about that? Thanks a lot. |
|
|
There shouldn't be any need for a licence file with SQLite. Can you confirm whether you're getting a BadImageFormatException or a FileNotFoundException? If the latter, it may just mean you have a different version of SQLite installed from what LightSpeed expects. |
|