How to import data from multiple worksheets contained in 1 workbook?
Show older comments
Hi,
I have a workbook SelfStorageData.xls . It contains 3 worksheets . I want to import data from each of these 3 worksheets as 3 different matrices. Here is my code:
T = readtable('SelfStorageData.xls');
However, I get the following error:
Unable to open file 'SelfStorageData.xls' as a workbook. Check that the file exists, read access is available, and the file is a valid spreadsheet file.
How can this be fixed? Excel Workbook attached.
Accepted Answer
More Answers (1)
Walter Roberson
on 22 Jun 2020
2 votes
Your file is SelfStorageData.xlsx but you try to read SelfStorageData.xls without the final 'x'
2 Comments
Monalisa Pal
on 22 Jun 2020
Edited: Monalisa Pal
on 22 Jun 2020
Opps sorry, I missed the attachment. I just followed the comment. Thanks for pointing it out. I'll edit my answer.
Purnjay Peshawaria
on 22 Jun 2020
Edited: Purnjay Peshawaria
on 22 Jun 2020
Categories
Find more on Spreadsheets in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!