Loading a dll from a dll?

After all the debate that went on in the comments, I think that it’s better to summarize my positions in a “real” answer. First of all, it’s still not clear why you need to load a dll in DllMain with LoadLibrary. This is definitely a bad idea, since your DllMain is running inside another call … Read more

DLL Load Library – Error Code 126

Windows dll error 126 can have many root causes. The most useful methods I have found to debug this are: Use dependency walker to look for any obvious problems (which you have already done) Use the sysinternals utility Process Monitor https://docs.microsoft.com/en-us/sysinternals/downloads/procmon from Microsoft to trace all file access while your dll is trying to load. … Read more