Hi,
I received an error trying to read my excell file parameters using a script. I don't think the problem is in the code because i used this script several times without any problems. But i don't know where to look for. I already used an excell file that worked last time, i closed all the excell processes, but i seems not to work. Do you have any suggestions how to resolve it?
matlab gives following error: Undefined function or variable 'xls2struct'.
the script is:
%loading excel file selected
[filename, pathname] = uigetfile({'*.xlsx','script XLSX file (*.xlsx)'});
pathx=[pathname filename];
disp('reading script parameters...');
%reading excel file parameters
[dx,nome_file,ext] = fileparts(pathx);
xls_data=xls2struct(pathx,'data'); %read data sheet
thanks a lot! greetings Nele

 채택된 답변

madhan ravi
madhan ravi 2018년 9월 28일
편집: madhan ravi 2018년 9월 28일

0 개 추천

There is no syntax as xls2struct maybe try xlsread if you want to read the file.
Or maybe try the file exchange below:

댓글 수: 1

Nele De Bruyn
Nele De Bruyn 2018년 10월 1일
i have found the problem. There is a second script to define the xls2struct function, but it was not in the same folder. Thank you for your suggestions!

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

제품

릴리스

R2015b

태그

질문:

2018년 9월 28일

댓글:

2018년 10월 1일

Community Treasure Hunt

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

Start Hunting!

Translated by