How could I make a program where an excel file is a input?
1 次查看(过去 30 天)
显示 更早的评论
I mean you have to tell the program just the name of the excel file. I know this doesn't work, but it can help you to understand what I mean.
function
P = input('excell name = ')
t = xlsread('P')
end
0 个评论
回答(1 个)
KSSV
2016-10-4
function t = readexel(filename)
if ~ischar(filename)
error('input hsould be a filename')
end
t = xlsread(filename)
end
You can try like the above.
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Data Import from MATLAB 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!