xlsread for multiple sheets?

1 view (last 30 days)
Matt Kocoloski
Matt Kocoloski on 17 Nov 2011
Hello,
Is it possible to import multiple sheets in an Excel workbook using a single call to xlsread? I have a ~100 MB spreadsheet with 72 tabs, each of which has the same format, which all need to be imported.
A single call of xlsread to this file takes about 45 seconds on my machine, and I'm wondering if there is a faster way than calling this function 72 individual times. Thanks a lot.
Matt

Accepted Answer

Fangjun Jiang
Fangjun Jiang on 17 Nov 2011
I don't think xlsread() currently supports it. You can use Excel COM server to speed up the process. Follow the link in this answer to see a brief introduction. The comments in the answer provide some code too.
  2 Comments
Matt Kocoloski
Matt Kocoloski on 28 Nov 2011
Thanks a lot, Fangjun. I had never used this functionality before, but it was exactly what I was looking for. Runtime is down from about an hour to about 2 minutes. Thanks buddy.
Fangjun Jiang
Fangjun Jiang on 28 Nov 2011
Wow, that's a lot of saving on time!

Sign in to comment.

More Answers (0)

Tags

Community Treasure Hunt

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

Start Hunting!