I am about to give up on this, every time I try to do a simple task I always get a major error. Plus there are like zero examples out there on how to use these databases.
First I try to create a simple db, I get an error about the dll file not being a valid .net file. This is the same .dll file that is packaged on the website in the source code. If you look at the file in windows explorer, it will show a filesize of 131k, well this file is not a valid .net file.
In order to get the code to create a db file, I had to recompile the System.Data.SQLite FULL project file, then the .dll file was recognized and I could create a new db.
Seems there are more problems after that. After you create the db file and you try to open it "dbfile.Open()", you get an error stating that this is not a valid call. EntryPointNotFoundException: Unable to find an entry point named 'sqlite3_open_interop' in DLL 'System.Data.SQLite.DLL'. I searched the web and came back with this result from the error.
//-------------------------------------
You shouldn't include the SQLite project files with your project. The SQLite project has several dependencies and custom build steps that you are missing. The reason you're getting this error is because the System.Data.SQLite-Full project is an "intermediate project" which builds ONLY the wrapper. The "SQLite.Interop" project is responsible for compiling the native engine and merges it with the wrapper in a custom build step.
By referencing only the SQLite project, you're only getting the wrapper and the native engine isn't being merged with the assembly.
//-------------------------------------
Now for someone who has never used sqlite before, and is just learning c#, this is very frustrating.
Can anyone recommend a flat file db that has lots of examples and pretty much works? I just want to write a simple db program that will run on my desktop, and it will run on my pocket pc too. Thats all, I am not trying to write hundreds of tables with multi threading or anything like that.
TIA