I can't get the LoadExtension() function to work under Visual Studio 2015 
Express C#. I have tried to load several extensions that do work under the 
SQLite console but they will not load under C#.  So I created the minimal 
example of an example extension given on sqlite.org using the half.c source. It 
loaded and worked under the SQLite console but failed to load it in a simple C# 
program with the code snippets shown here:


using System.Data.SQLite;

        SQLiteConnection m_dbConnection;


        string str_extension_path = @"C:\Users\Admin\Documents\Visual Studio 


        string str_DB_Connect = "Data Source=" + textBox_DBPath.Text.ToString() 
+ "; Version=3;";
        m_dbConnection = new SQLiteConnection(str_DB_Connect);

The program had this exception when the .LoadExtension() executed:

"An unhandled exception of type 'System.Data.SQLite.SQLiteException' occurred 
in System.Data.SQLite.dllexception
Additional information: SQL logic error or missing database

The specified module could not be found."

I've tried many other approaches, for example, using SELECT 
load_extension('half.sqlext'), and rebuilt everything in x86 and x64 but to no 

Does anyone have a working example with source of an extension and a working VS 
2015 C# program that loads it? Or doesn't this feature work.


sqlite-users mailing list

Reply via email to