ASP.NET에서 Excel 문서를 동적으로 생성 할 때 '라이센스 만료'오류

StackOverflow https://stackoverflow.com/questions/254207

  •  05-07-2019
  •  | 
  •  

문제

아래 오류에 익숙한 사람이 있습니까? 로컬 컴퓨터에서 동적 Excel Doc을 생성하기 위해 WebApp을 실행하면 정상적으로 작동하지만 서버에서 동일한 코드가 호출되면 아래 오류가 발생합니다. 내 컴퓨터에서 작동하지만 서버에서는 작동하지 않기 때문에 권한 문제인 것 같습니다. 그러나 문제를 정확히 찾아 내기 위해 어디에서 시작 해야할지 모르겠습니다. 모든 지침/도움말은 대단히 감사합니다!

Server Error in '/' Application.
--------------------------------------------------------------------------------

This command is unavailable because the license to use this application has expired. 
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 

Exception Details: System.Runtime.InteropServices.COMException: This command is unavailable because the license to use this application has expired.

Source Error: 

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.  

Stack Trace: 


[COMException (0x800a03ec): This command is unavailable because the license to use this application has expired.]
   Microsoft.Office.Interop.Excel.Workbooks.Add(Object Template) +0
   PaymentsReport.Page_Load(Object sender, EventArgs e) +70
   System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +15
   System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +34
   System.Web.UI.Control.OnLoad(EventArgs e) +99
   System.Web.UI.Control.LoadRecursive() +47
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1061

Office/Excel은 서버에 설치되며 서버에서 Excel 문서를 열/저장할 수 있습니다. 서버와 내 로컬 컴퓨터의 Excel 버전 일 수 있습니까? 그렇다면 어떻게 서버에 최신 정보를 얻을 수 있습니까?

도움이 되었습니까?

해결책

Office Interop을 사용하려면 사용중인 사무실 구성 요소가 실제로 서버에 설치되어야합니다.

다른 팁

설치되는 것 외에도 서버에서 응용 프로그램이 활성화되어 있는지 확인해야합니다.

http://support.microsoft.com/kb/294973

이 작업을 수행하는 방법에 대한 세부 정보가 있습니다.

나는 흔들림을 받고 서버에서 사무실 사본을 때리고 여러 사용자가 웹 사이트를 통해 액세스 할 수 없다고 말할 것입니다. 서버 환경에서 MS Office를 사용하기위한 라이센스 제한을 살펴 봐야합니다.

서버에 라이센스, 활성화 된 Excel 사본이 있습니까? Office/Excel이 로컬로 설치되어 있기 때문에 로컬 컴퓨터에서 작동 할 것입니다.

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