xlsread unable to open file
24 次查看(过去 30 天)
显示 更早的评论
I have been messing with this for a while now but have no clue what to change. The error is in line 4, any ideas?
0 个评论
采纳的回答
Stephan
2018-9-20
编辑:Stephan
2018-9-20
Hi,
path = 'C:\Users\Stephan\Desktop';
filename = 'test.xlsx';
fullpath = [path, '\', filename];
data = xlsread(fullpath,'A1:B2');
is one possibility of solving this problem.
path = "C:\Users\Stephan\Desktop";
filename = "test.xlsx";
fullpath = join([path, filename],"\");
data = xlsread(fullpath,'A1:B2');
Note that double quotes are used now.
Best regards
Stephan
更多回答(0 个)
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!