Excel (.csv) error: "Excel Worksheet could not be activated.""
7 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
I am trying to read a column from a csv file.
filename = 'sample.csv';
Longitude = xlsread(filename,'D:D');
when I execute these lines, I get an error that says "Excel Worksheet could not be activated". This error does not accur when I reduce the number of rows in the sheet to 100 (originally it has ~400,000 rows). Does this problem occur because of the large number of rows? Is there a way around it?
1 Kommentar
Easwar Kumar Yarrabikki
am 14 Mär. 2019
I faced this issue when I ignored an MS Office update for several days. Once I have updated and MS office and restarted my machine issue got resolved. Also make sure your MS Office account is also up to date.
Antworten (1)
Bob Thompson
am 14 Mär. 2019
A .csv file is not actually an excel format, although it can be opened with excel. I would suggest using csvread() instead, as it allows you to work directly with the proper format.
I believe it is possible to load .csv files directly with xlsread, however, you are not able to specify which sheet should be used (because .csv files cannot have multiple sheets), and specifying the range is not going to follow the same format (because .csv files do not have letter designated columns).
0 Kommentare
Siehe auch
Kategorien
Mehr zu Spreadsheets finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!