Project can't recognize dll in x64 machine - c#

I need to create a Custom Download Manager, because I don't want the Internet Explorer to fire de Default File Download Dialog.
Then, I got this example to do: http://www.codeproject.com/Articles/18935/The-most-complete-C-Webbrowser-wrapper-control
I've downloaded the example code and tried to run it. after registering the DLL the program didn't recognize. The whole problem is the x64 and x86 bits thing. I work on a x64 bits machine, and it doesn't work
Then I got this post: wrap 32 bit dll for 64 bit operating system to work with regsvr32.exe
and tried the solutions, but the same exception was still there.
Exception:
An unhandled exception of type 'System.UnauthorizedAccessException' occurred in csExWB.dll
Additional information: Access denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED))
I really need your help, and don't know what else to do. This download manager is vital to my project.
I appreciate any help.

Related

I am unable to use Nuget Nlua to read .lua file in C#

Using visual studio with class application I added the NLua via NuGet.
I want to read in and .lua file (BTW, of there is a better way do let me know)
My code is this:
...
using NLua;
...
using (Lua lua = new Lua())...
But when I run it I get an exception on the above line:
System.BadImageFormatException
HResult=0x8007000B
Message=An attempt was made to load a program with an incorrect format. (Exception from HRESULT: 0x8007000B)
Source=KeraLua
StackTrace:
at KeraLua.NativeMethods.luaL_newstate()
at NLua.Lua..ctor()
What am I doing wrong? I tried to search the internet and came up with solutions that it is since I am running a 64bit app while the one I am trying to load (NLUA) in 32bit.
Is that it?
THANK YOU

C# error: Unable to load DLL 'AutoItX3.dll': The specified module could not be found. (Exception from HRESULT: 0x8007007E)

DLL is available inside 'References'.
I can able to run the test using 'Test Explorer' successfully
Problem:
Same test when im running from mstest commands- im getting the following error,
error: Unable to load DLL 'AutoItX3.dll': The specified module could not be found. (Exception from HRESULT: 0x8007007E)
Where i'm wrong ? can anyone show me the way for resolving this issue!
Thanks for your help
This seems to be late, but if you still need an answer, here is my way: Change platform target of your project.
In visual studio, right click project -> Properties -> Build > Platform target -> Try to change x86 or x64.
platform target
Do one thing
register your AutoItX3.dll:
Bu opening the CMD in Administration and execute the below command, change the path of according to your location
regsvr32 "C:\Program Files (x86)\AutoIt3\AutoItX\AutoItX3.dll"
you will get a message box telling you it was successful.
Now try to run the test

EmguCV: Unable to load DLL 'cvextern': The specified procedure could not be found

When publishing project to windows server 2003 (old test machine) I get following error when trying to call open cv functions.
Additional information: The type initializer for 'Emgu.CV.CvInvoke' threw an exception.Unable to load DLL 'cvextern': The specified procedure could not be found. (Exception from HRESULT: 0x8007007F)
I am using EmguCV 3.4.1 version with uploaded libraries:
vcruntime140.dll
opencv_ffmpeg341.dll
msvcp140.dll
cvextern.dll
concrt140.dll
To the Emgu package nothing extra (dll's) were added and on developer machine I could develop the application.
I keep wondering whether additional native dll's should be added. I downloaded binaries for 3.4.1 version. The files go like that:
opencv_core249.dll
opencv_highgui249.dll
Those two above where in 3.4.1 package. When i copied them to program directory it didn't help either.
What's more I have no idea how to track down the problem.
Process monitor doesn't show that the process is looking for something that cannot be loaded.
In the inner exception I am given only this exception: Unable to load DLL 'cvextern': The specified procedure could not be found. (Exception from HRESULT: 0x8007007F)
I had to install "Desktop Experience" feature on my server. Because server 2003 doesn't seem to have it, I had to move it to another server 2008 host.

LibX11 Exception on C# Visual Studio

I want to create a program in C# that uses OpenTK. I download the nuget package with this:
nuget.exe install OpenTK
and also
nuget.exe install OpenTK.GLControl
But whenever I reference these 2 files, the console ends up printing this error:
Exception thrown: 'System.DllNotFoundException' in OpenTK.dll
Additional information: Unable to load DLL 'libX11': The specified module could not be found. (Exception from HRESULT: 0x8007007E)
And upon further investigation, libX11 is a Linux package but I'm running on Windows 10. Is there a way to bypass the Linux check and be able to use it on Windows?
There is no code with it because I can't even properly reference the file without it printing that exception.
I have attempted to put this into System32 and all to no avail.

How to add sqlite3.dll for win rt as a reference?

I am building a Windows Store app that targets an ARM device (Windows RT tab), I installed the NuGet pkg SQLite-net and it works perfectly under x86 platform. But when I tested on the ARM device (note that platform target has been setup for ARM by this time), I get the following error:
An exception of type 'System.DllNotFoundException' occurred in
App1.exe but was not handled in user code
Additional information: Unable to load DLL 'sqlite3': The specified
module could not be found. (Exception from HRESULT: 0x8007007E)
I have not been able to add the sqlite3.dll from the SQLite.org website, I tried to add as a "existing item", change its properties as content, copy always; but I keep getting the same error.
my Connection path is following:
// C#
public static string sqlitedbPath = Path.Combine(
Windows.Storage.ApplicationData.Current.LocalFolder.Path, "mydb.s3db");
I am sure I have the wrong DLL, but I am having I hard time to change it.
Does somebody has a good solution?

Categories

Resources