Questions tagged [loadlibrary]
558 questions
-1
votes
4 answers
Have to do FreeLibrary 2 times although I have done LoadLibrary only 1 time. Also, after unloading DLL, when trying to load it again, error happens
Have the following C# code for loading and unloading a C++ DLL.
I load DLL only once, but code has to unload DLL 2 times. Also after unloading DLL, when I load it again, and I call DLL's exported function, I get the following error message:…

Megidd
- 7,089
- 6
- 65
- 142
-1
votes
1 answer
LoadLibrary fails when called from process run as Standard User on Windows Server 2008 with Terminal Services
We have a .NET library that platform invokes native code, specifically we call LoadLibrary(). This code has been in place for a while, but a new user has noticed when running as a Terminal Services user of a Windows Server 2008 R2 machine that it…

JosephA
- 1,187
- 3
- 13
- 27
-1
votes
2 answers
Injected DLL not correct HMODULE
So I am injecting a DLL into a program. I can verify that the DLL is injected with help from Process Explorer. After the injection I am looping all modules from the process, comparing the names and return the injected dll as a HMODULE.
Then I…

user616396
- 35
- 8
-1
votes
1 answer
java.lang.UnsatisfiedLinkError Android
I am using follow code in android.
System.loadLibrary("openal");
When Running the application it gives run time error as below.
java.lang.UnsatisfiedLinkError: Couldn't load openal from loader
dalvik.system.PathClassLoader[DexPathList[[zip file…

manitaz
- 1,181
- 2
- 9
- 26
-1
votes
1 answer
Windows LoadLibrary I can not load the dll from folder
Hello I can not load the dll from a selected folder
using the Windows LoadLibrary
receives a conditional statement "can not load library"
Here's the code.
-1
votes
1 answer
get string from a dll inside another dll
Here is the case:
I made a dll with a function1 inside as below:
int function1( char *inVal, char *outVal)
{
....
strcpy(outVal,dn.commonname.c_str());
}
in the last line outVal is pointed to dn.commonname which is a string.
I loaded this dll in…

A23149577
- 2,045
- 2
- 40
- 74
-2
votes
1 answer
How can I export a macro function and use it in a project .exe?
I have a dll project (Server.dll) containing a Server.cpp
Server.cpp
#include "pch.h"
#include "Server.hpp"
extern "C" {
_declspec(dllexport) int Server::Add(int a, int b)
{
return a + b;
}
}
#define Function( Y ) \
\
extern…

SADL
- 37
- 5
-2
votes
1 answer
C# - Problems with kernel32.dll's GetProcedureAddress
I am P/Invoking LoadLibrary, and loading opengl32.dll. I have delegates and loading code for all the OpenGL functions, just like this example below:
internal delegate void ActiveShaderProgram(UInt32 pipeline, UInt32 program);
IntPtr…
user11494366
-2
votes
1 answer
Linking an unknown dll
I've got this dll (called unknown.dll) from which i only know what Ghidra told me. I'm using LoadLibraryW to load it, but (in x86) it throws me the error 126. However, in 64x it gives me the error 193, so i don't think that the problem is that my…

Guibi
- 115
- 1
- 7
-2
votes
1 answer
LoadLibrary failed when running Loadrunner 12.53
Fatal Error -32988: LoadLibrary failed, rc=193 [MsgId: MERR-32988]
Fatal Error -26000: xfbLrwiWebInfraGlobalInitOK failed [MsgId: MERR-26000]
Warning: Extension lrwreplaymain.dll reports error -1 on call to function…

Wing Yan Yeung
- 69
- 1
- 7
-2
votes
2 answers
loadlibrary fails with error code 127
I've a very interesting problem. It's sounds very easily, but I didn't finf any information about it.
I've a C# solution with excel Add-in and winforms application and library project with only one method.
project with library have next…

qpIlIpp
- 29
- 4
-2
votes
1 answer
EXE and DLL Loading shared DLL leads to Invalid Pointer Operation and hang on termination
I have an Executable project which uses another DLL project and loads it dynamically using LoadLibrary and GetProcAddress. On the other hand, I have another second DLL which is used by both the EXE and the first DLL, also using LoadLibrary and…

Jerry Dodge
- 26,858
- 31
- 155
- 327
-2
votes
1 answer
Loading CLR dll from Native code
I am trying to use the following code:
LoadLibraryExA(filename.c_str(), NULL, DONT_RESOLVE_DLL_REFERENCES);
To load a C++\CLR dll from a native assembly.
The HMODULE returned is NULL and the GetLastError returns - 193 which means is not a valid…

Ron Gross
- 1,474
- 5
- 19
- 34
-3
votes
1 answer
Loading a C# assembly (compiled to a .dll) in VBA
I have an existing codebase of C++/CLI calling C# and want to drive both of these from VBA. The C# code is called from the C++/CLI and works great if I run it all using a simple C++ exe. The problem is, I am now trying to invoke the C++/CLI (and…
-3
votes
1 answer
How do I solve Error 126/193 from using Loadlibrary?
I'm working a on project to use the SDK from https://github.com/hypersen/HPS3D_SDK
but I'm having troubles loading the DLL file, it returns me an error 126 for "libhps3d32.dll" and error 193 while using "libhps3d64.dll". I've seen many posts…

Jerru
- 99
- 1
- 9