当前位置: 动力学知识库 > 问答 > 编程问答 >

Missing .dll when I try to run my application

问题描述:

I have been working with OpenGL (SuperBible) and I just setup my environment (added the additional dependencies, etc.) and built my solution. When I try to execute it it says I am missing a dll. I solved the problem by moving the dll to my folder where the executable resides.

My question is why doesn't it look for it in my System32 folder? Why does it have to be in the folder with the executable. And finally is there a way to make it look for it in the System32 folder?

网友答案:

Check the value of your %PATH% environment variable.

set PATH

If system32 isn't in your path, thats why you can't find the dll.

As for why the DLL must be in the same folder, there are two possible culprits:

1) Your code has a Hard Coded Path to the Dll 2) The DLL isn't in any place that is listed in the %PATH% system variable.

网友答案:

IIRC there is something about registering DLLs. (Truth be told, I avoid DLLs whenever I can so I might be way off base.)

分享给朋友:
您可能感兴趣的文章:
随机阅读: