locked
using SQLite PCL, Unable to load DLL 'sqlite3': error

    Question

  • I know that this question has been asked a lot, but I've tried all of the solutions that I could think of.

    I'm using SQLite PCL, SQLite.Net / Async via NuGet. I have 5 projects in my solution, WP8, W8.0, PCL, SQLite.Net, SQLite.Net.Async.

    I'm getting this error when I call the database. I've tried manually copying precompiled binaries into the bin folders and changing the project configuration between 32 and 64 bit.

    Any suggestions? Thanks for the help.


    Michael DiLeo

    Saturday, April 5, 2014 3:36 PM

Answers

  • Hi,

    Can you clarify the ".NET Extension as a reference"? For windows store app,  SQLite is not .NET so you need to make sure that you are including a reference to "SQLite for Windows Runtime" in the Add References...Windows\Extensions section. You can download and install this via Visual Studio (requires a restart of the IDE).  Then, go to your WinRT project, Add a Reference, under "Windows" choose "Extensions" and you should see it.

    enter image description here

    You can refer to the link below:

    http://blogs.msdn.com/b/robertgreen/archive/2012/11/13/using-sqlite-in-windows-store-apps.aspx

    Best Wishes!


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey. Thanks<br/> MSDN Community Support<br/> <br/> Please remember to &quot;Mark as Answer&quot; the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Tuesday, April 8, 2014 3:06 AM

All replies

  • What errors are you getting?
    Saturday, April 5, 2014 6:11 PM
  • Thank you for responding. The error is Unable to load DLL 'sqlite3': The specified module could not be found. (Exception from HRESULT: 0x8007007E)

    Michael DiLeo

    Saturday, April 5, 2014 6:15 PM
  • Hi, additionally to the bin folder, try to add the dll on the root of your project(s), and be sure that you project is not set to "All Cpu".
    Saturday, April 5, 2014 6:51 PM
  • I tried putting the 64bit debug into the W8 project root and running as Debug and x64 on the project, but with the same issue. Here is out of place with this?y build configuration. Is anything out of place with this?

    Michael DiLeo

    Saturday, April 5, 2014 8:56 PM
  • Hi,

    Can you clarify the ".NET Extension as a reference"? For windows store app,  SQLite is not .NET so you need to make sure that you are including a reference to "SQLite for Windows Runtime" in the Add References...Windows\Extensions section. You can download and install this via Visual Studio (requires a restart of the IDE).  Then, go to your WinRT project, Add a Reference, under "Windows" choose "Extensions" and you should see it.

    enter image description here

    You can refer to the link below:

    http://blogs.msdn.com/b/robertgreen/archive/2012/11/13/using-sqlite-in-windows-store-apps.aspx

    Best Wishes!


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey. Thanks<br/> MSDN Community Support<br/> <br/> Please remember to &quot;Mark as Answer&quot; the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Tuesday, April 8, 2014 3:06 AM