0

I am working on vb.net windows form application ,i need to create SQL lite database for my windows CE device, so i given code like this in my windows form application

SQLiteConnection.CreateFile("D:\\mydatabasefile.sdf")
        Dim connection As New SQLiteConnection

        Using Query As New SQLiteCommand()
            connection.ConnectionString = "DataSource=c:\mydatabasefile.sdf;Version=3;New=False;Compress=True;"
            Connection.Open()
            With Query
                .Connection = Connection
                .CommandText = "CREATE TABLE MyTable(CustomerID INTEGER PRIMARY KEY ASC, FirstName VARCHAR(25))"
            End With
            Query.ExecuteNonQuery()
            Connection.Close()
        End Using

so its creating mydatabasefile.sdf database in D drive,but while coming second line of code. "Dim connection As New SQLiteConnection" it throwing error. Unable to load DLL 'SQLite.Interop.dll': The specified module could not be found. (Exception from HRESULT: 0x8007007E)

I already added below dll in the reference, System.Data.SQLite i am working on visual studio 2010..I have check all possible solutions from google.but nothing worked for me,.,

any help is very appreciable ..

i am working on OS Win7 32

user3262364
  • 369
  • 3
  • 9
  • 23
  • Possible duplicate of [Unable to load DLL 'SQLite.Interop.dll'](http://stackoverflow.com/questions/13028069/unable-to-load-dll-sqlite-interop-dll) – Alex K. Apr 03 '17 at 13:07
  • @AlexK. i have already checked all possibility in that link.,but nothing worked for me,,,,so please dont say duplicate.. – user3262364 Apr 03 '17 at 13:12

0 Answers0