Excel integration is not available in programs developed with C#

장현덕 1 Reputation point
2021-06-11T06:52:28.053+00:00

C#으로 개발한 프로그램에서 엑셀 연동이 되지 않습니다.
프로그램에서 엑셀과 연동해 놓은 버튼을 클릭하면 엑셀이 실행이 되어야 하는데 오류메시지가 뜹니다.

오류 메시지: 'Excel.ApplicationClass' 형식의 COM 개체를 인터페이스 형식 'Excel._Application'(으)로 캐스팅할 수 없습니다. 라이브러리가 등록되지 않았습니다. (예외가 발생한 HRESULT: 0x8002801D (TYPE_E_LIBNOTREGISTERED)) 오류로 인해 IID가 '{000208D5-0000-0000-C000-000000000046}'인 인터페이스의 COM 구성 요소에서 QueryInterface를 호출하지 못했으므로 이 작업을 수행할 수 없습니다.

현재까지 제가 알고 있는 해결방법은 윈도우를 포맷 후 재설치 후 office를 재설치 하여 해결하는 부분입니다.
윈도우 포맷 안하고 office만 삭제 후 재설치 해보아도 동일하게 오류메시지가 뜹니다.
윈도우 포맷 후 재설치하는 번거로움 없이 바로 조치 해결 할 수 있는 방법은 안내부탁드립니다.

빠른 답변 부탁드립니다.


Translated from Korean to English:

Excel integration is not available in programs developed with C#.
If you click the button East Sea and open in the program, excel should be executed, and an error message will be made.

Error message: Com object in 'Excel.ApplicationClass' type could not be Excel._Application to interface type 'Excel'. The library is not registered. (This operation could not be done because the IID failed to call QueryInterface from the COM component of the interface with '{000208D5-0000-0000-C0000-0000000046}' due to an HRESULT: 0x8002801D (TYPE_E_LIBNOTREGISTERED)) error that caused the exception.

The solution I know to date is to format windows, reinstall it, reinstall office, and fix it.
If you do not format Windows and delete and reinstall office only, you will see the same error message.
We will provide you with a way to fix the action immediately without the hassle of reinstalling it after windows format.

Please get a quick response.

0 comments No comments
{count} votes