문제

I have created a COM DLL in C#. In this DLL I am linking against a third party DLL ("thirdpartydll.dll"). When I set "thirdpartydll.dll" to be output into the Release folder during the compilation, all works fine.

But I do not want to distribute "thirdpartydll.dll" with my DLL. I would like my DLL to use the "thirdpartydll.dll" that may (or may not) have been registered by the third party.

For example, if the third party installed "thirdpartydll.dll" to C:\Program Files (x86)\Third Party\thirdpartydll.dll, then my COM DLL should use this.

Currently this does not work. I get the automatic error 80070002. I guess it means that my COM DLL can not find "thirdpartydll.dll". I am not sure why. I thought my COM DLL would find it automatically.

올바른 솔루션이 없습니다

다른 팁

If you do not want to care where (non COM) thirdparty.dll is installed on the target system, it has to be install into the Global Assembly Cache (GAC).

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top