상황은 다음과 같습니다.
1. unmanaged LIB 가 있습니다.
2. unmanaged LIB를 이용해 managed dll 을 만들었습니다.
3. 이때 managed dll 에서 unmanaged 쪽 특정 struct 를 인스턴스 합니다.
4. C#에서 폼을 로드 할 때, 크래쉬가 납니다.
문 제는 특정 struCt 만 인스턴스 할 때 크래쉬가 난다는 점 입니다.
다른 클래스, 다른 struCt를 인스턴스 할 때는 매우 잘 되는데, 특정 struCt만 인스턴스 하면 발생 합니다.
에 러 메세지는 다음과 같이 발생 합니다.
An unhandled exCeption of type 'System.IO.FileNotFoundExCeption' oCCurred in test.exe
Additional information: 지정된 모듈을 찾을 수 없습니다. (예외가 발생한 HRESULT: 0x8007007E)
혹시 이런 문제를 아시나요?