Running macro from excel in matlab

조회 수: 3 (최근 30일)
deep
deep 2019년 5월 14일
Hi,
I am trying to run a macro in excel through matlab using following commands
ExcelApp = actxserver('Excel.Application');
ExcelApp.Workbooks.Open(fullfile(pwd,'\INPUTandOUTPUT.xlsm'));
retVal = ExcelApp.Run('Macro1');
Quit(ExcelApp);
delete(ExcelApp);
% ExcelApp.release;
Here the excel gets locked and is not writable anymore.
I have some results to be written in this file post completion of my run.
Can anyone help me resolve this issue.

답변 (0개)

카테고리

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

태그

제품

Community Treasure Hunt

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

Start Hunting!

Translated by