Why does using ActiveX in MATLAB Web App Server fail with "Server Creation Failed : Access denied" errors?

조회 수: 11 (최근 30일)
I am working with a deployed web app, in which I am trying to use the ActiveX interface. I am working with ActiveX because I create both tables and Excel figures as part of an Excel report.
The errors I run into are the following:
Error using feval Server Creation Failed : Access denied Error in actxserver (line 89) The offending line in their code is: Excel = actxserver('Excel.Application');
Everything works fine in a non-deployed environment.

채택된 답변

MathWorks Support Team
MathWorks Support Team 2024년 12월 4일 0:00
Using Excel in Web Apps is not recommended as per Microsoft's help page:
        "Microsoft does not currently recommend, and does not support, Automation of Microsoft Office applications from any unattended, non-interactive client application or component (including ASP, ASP.NET, DCOM, and NT Services), because Office may exhibit unstable behavior and/or deadlock when Office is run in this environment."
The recommended approach
The recommended approach is to use "readtable" / "writetable" without invoking Excel behind the scenes ('UseExcel=false'), and reimplement figures as MATLAB "UIAxes" controls in AppDesigner.
Running report generator reports using "
rptview()
" will not work in web apps, since it will open another window.
You may be able to use MATLAB report generator in web apps, but offer to download generated report via web link to users. If report viewing inside web app is desired, it is possible to use R2019b HTML control to load HTML report generated by MATLAB.
 

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 ActiveX에 대해 자세히 알아보기

제품


릴리스

R2018b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by