Invalid file identifier.Use fopen to generate a valid file identifier

2 次查看(过去 30 天)
I am getting this error :
Invalid file identifier.Use fopen to generate a valid file identifier
Once it goes through my data without any and others this error occur. I add that i have 11 thousand files to open and then to write it in other directory. It occurs sometimes at the end sometimes and the beginning and sometimes it goes without error. Any ideas what my happend? I don't paste the code because in my opinion it's something different because it works but not all the time.
The error is saving : too many open files.
Why is it , because I am having only one file open . I close it everytime at the end of the loop.
  1 个评论
Cedric
Cedric 2013-8-5
Well, I think that the code would help actually.
Otherwise, check that you are closing files in all cases (sometimes people return from a function or break out a loop and forget to close open files). If you are generating file names, check that you are not using invalid characters, and when you open files, check that the fid returned by FOPEN is valid.

请先登录,再进行评论。

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Get Started with MATLAB 的更多信息

产品

Community Treasure Hunt

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

Start Hunting!

Translated by