-
-
Notifications
You must be signed in to change notification settings - Fork 176
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error in Visual Studio 2017 - Unable to load DLL 'e_sqlite3': The specified module could not be found. #599
Comments
What happens if you copy the e_sqlite3.dll file from the x86 folder to the folder above? |
Same thing. |
I am discussing a fix: dotnet/efcore#10596 |
Okay, Thank you. |
Fixed in the latest build, let me know if it works for you! |
Yes it works now, but when I select reverse engineer and point it to my SQLITE database, the only thing that happens is I get a json config file only. There are no code files. |
Check the VS ouput window - does your tabels have primary keys - this is required? |
Sorry, I hadn't noticed the debug windows, that even though it went further than before, I had the error message below. System.TypeInitializationException: The type initializer for 'Microsoft.Data.Sqlite.SqliteConnection' threw an exception. ---> System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.DllNotFoundException: Unable to load DLL 'e_sqlite3': The specified module could not be found. (Exception from HRESULT: 0x8007007E) |
C:\projects\sqlcetoolbox\src\GUI\EFCorePowerTools\Handlers\ReverseEngineerHandler.cs:line 120 |
Used daily build from EF Core Power Tools Wiki below. Useful design-time DbContext features, added to the Visual Studio Solution Explorer context menu. Watch demo on Channel 9 Download from Visual Studio MarketPlace Download daily build <------------------------------------ |
I cannot reproduce with the latest daily build - can you share a reproduce project and provide VS version |
Do I need to update SQLite/SQL Server Compact Toolbox too? |
No. Which Power Tools version do you have? |
I see that you put e_sqlite3 into the root folder too. I have version 1.0.486 |
Yes, that was my fix. Let me do some more testing |
I was able to repro. Will try out this fix: aspnet/Microsoft.Data.Sqlite#249 (comment) |
Ok, I had saw that too. That might work out. |
Trying this:
|
Made another attempt at fixing: dotnet/efcore#10596 (comment) - in the latest daily build - please let me know if i works for you! |
Yes, it worked. |
You are welcome, thank you for reporting this issue |
No problem. |
In Visual Studio when I right click on a project, and the select:
EF Core Power Tools --> Reverse Engineer -->
Choose Database Connection --> Select Tables To Script -->
Generate EF Core Model In Project ...
I get the Error below.
I'm using EF Core Power Tools V.1.0.481 Daily build, and I was using the version from VS Gallery.
Both have same Problem.
I checked ...\AppData\Local\Microsoft\VisualStudio\15.0_5f11fda6\Extensions\uba5o5io.zok
and e_sqlite3.dll file (IS LOCATED IN) both x86 and x64 directories.
Thank you
System.TypeInitializationException: The type initializer for 'Microsoft.Data.Sqlite.SqliteConnection' threw an exception. ---> System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.DllNotFoundException: Unable to load DLL 'e_sqlite3': The specified module could not be found. (Exception from HRESULT: 0x8007007E)
at SQLitePCL.SQLite3Provider_e_sqlite3.NativeMethods.sqlite3_libversion_number()
at SQLitePCL.SQLite3Provider_e_sqlite3.SQLitePCL.ISQLite3Provider.sqlite3_libversion_number()
at SQLitePCL.raw.SetProvider(ISQLite3Provider imp)
at SQLitePCL.Batteries_V2.Init()
--- End of inner exception stack trace ---
at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
at System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at Microsoft.Data.Sqlite.Utilities.BundleInitializer.Initialize()
at Microsoft.Data.Sqlite.SqliteConnection..cctor()
--- End of inner exception stack trace ---
at Microsoft.Data.Sqlite.SqliteConnection..ctor(String connectionString)
at Microsoft.EntityFrameworkCore.Scaffolding.Internal.SqliteDatabaseModelFactory.Create(String connectionString, IEnumerable
1 tables, IEnumerable
1 schemas)at Microsoft.EntityFrameworkCore.Scaffolding.Internal.RelationalScaffoldingModelFactory.Create(String connectionString, IEnumerable
1 tables, IEnumerable
1 schemas, Boolean useDatabaseNames)at Microsoft.EntityFrameworkCore.Scaffolding.Internal.ModelScaffolder.Generate(String connectionString, IEnumerable
1 tables, IEnumerable
1 schemas, String projectPath, String outputPath, String rootNamespace, String contextName, Boolean useDataAnnotations, Boolean overwriteFiles, Boolean useDatabaseNames)at ReverseEngineer20.EfCoreReverseEngineer.GenerateFiles(ReverseEngineerOptions reverseEngineerOptions)
at EFCorePowerTools.Handlers.ReverseEngineerHandler.d__2.MoveNext() in C:\projects\sqlcetoolbox\src\GUI\EFCorePowerTools\Handlers\ReverseEngineerHandler.cs:line 111
The text was updated successfully, but these errors were encountered: