XLSREAD error line 260: Out of Present Range
5 views (last 30 days)
Show older comments
My script which has been running fine for over a year developed a bug when I did a minor update to the Excel file that it was calling. Between the last time I used this script and now, I also updated to R2018a, but I can't imagine that would have a notable impact on this. Using Office Pro Plus 2016. I tried restarting multiple times, ensuring that all instances of Excel aren't running, but the problem persists. The full error is:
"Error using xlsread (line 260) Invoke Error, Dispatch Exception: Out of present range."
Any ideas would be much appreciated.
1 Comment
Charles Latchoumane
on 30 May 2019
I know this is not a good fix but it worked for me, switch you xlsread to 'basic' (adding it in your xlsread option), this will force to read the xls. I also went through the steps to disable add in and graphic acceleration, untick ignore DDE programs (this all alone didn't do it).
Hope it helps whoever wants to move on quickly.
Answers (1)
Walter Roberson
on 5 Jan 2018
Is it possible that add-ons to Excel accidentally got turned on? https://www.mathworks.com/matlabcentral/answers/98261-why-do-some-excel-processes-fail-to-terminate-after-using-xlsread-xlswrite-or-xlsfinfo-in-matlab
3 Comments
Walter Roberson
on 5 Jan 2018
Edited: Walter Roberson
on 5 Jan 2018
Potentially related: https://www.excelforum.com/excel-programming-vba-macros/521380-out-of-present-range-error-using-excel.html and https://social.msdn.microsoft.com/Forums/sqlserver/en-US/af5d73cc-a7e4-4544-aa1c-555487c11d8d/out-of-present-range?forum=sqldataaccess
Could the minor change to the file have made it larger enough to have tickled a data type overflow or to have exceeded the Excel maximum rows limit ?
See Also
Categories
Find more on Matrix Indexing 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!