Hello dear friends,
I have a problem with using xlsread on a large amount of files (over 9000 excel files). When I try to read every single one of them, I get a random error after about 5000 files. When I manually continue with the exact same file that causes the error, it will work just fine. But I am working on automatically reading all the files without having to manually correct each time I try to load them into my workspace.
So what I tried to do is that I used try and catch, something like this (pseudo-code):
i=1;while i<MaxNumberOfFilestrydata(i) = xlsread(...);i=i+1;catchendend
But it won't work since it's caught in the loop without end (always catches the same error). I think it might have something to do with restarting the whole "Matlab-running-the-process" when I manually correct the error and it works. Did anyone experience something like that before and could I avoid the error by using something like a timeout or memory-refreshing?
Looking forward to your ideas
Roman
Best Answer