Could not load file or assembly The system cannot find the file specified

前端 未结 5 925
孤城傲影
孤城傲影 2020-12-10 11:40

I am building a dll, which references a second dll. I have added the second dll as a reference in the first dll\'s project by going to Properties > Common Properti

5条回答
  •  被撕碎了的回忆
    2020-12-10 11:45

    As pointed out in the comments, SysInternals' Process Monitor is a valuable tool to diagnose DLL resolution problems. Tells you when a 3rd party DLL has a dependency you don't know about, also tells you when Windows is looking in the wrong corner of your hard drive for the file or finds the wrong one.

    Loader snaps is the built-in diagnostic tool for Windows. But Process Monitor is far more convenient.

    It does generate rather a lot of information, start from the bottom of the trace or enable tracing at just the right time. You often need to use its filtering tools to turn the firehose in a relevant trickle. Worth the hour of your time to figure it out, this tool belongs on any programmer's black belt.

提交回复
热议问题