not able to use "actxserver" command in linux

조회 수: 9 (최근 30일)
Nitin
Nitin 2023년 7월 28일
편집: dpb 2023년 7월 30일
Hello All,
Using m-script, I am accessing excel files. e.g. opening the excel file, renaming sheets, adding data to excel sheets.
These m-scripting commands works well in windows operating system. I am able to open, edit, rename sheets in excel.
But I am not able to do so on linux operating system. (Finally I want my m-script to run on Linux system)
After a bit of search I found that "actxserver" supports only on windows operating system.
So please let me know is there any alternative for "actxserver" on Linux operating system.
Please find the commands that I am running:
% # open Activex server
e = actxserver('Excel.Application');
% # open file (enter full path!)
ewb = e.Workbooks.Open(strcat(filename_testvector.folder, filesep, filename_testvector.name));
ewb.Worksheets.Item(1).Name = sheetname_testvector; % # rename 1st sheet
e.Visible = 1;
ewb.SaveAs(strcat(testpathName,filesep, newfilename_testvector));
ewb.Close(false)
e.Quit
e.delete

답변 (1개)

dpb
dpb 2023년 7월 28일
편집: dpb 2023년 7월 30일
No.
Even if the target machine has Excel installed and running under Wine, there's no port of the COM communications infrastructure to support it. MS simply has no interest in supporting the competing OS and the level of effort to reproduce it in the open software community is simply too large and too much proprietary stuff to hack around it'll never happen.
Whether there's any way to do such things with Open Office or the like I don't know; probably not...

카테고리

Help CenterFile Exchange에서 Use COM Objects in MATLAB에 대해 자세히 알아보기

제품


릴리스

R2022b

Community Treasure Hunt

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

Start Hunting!

Translated by