fopen works fine in *.m but fails in compiled Matlab
Show older comments
I use something like:
fpCSV = fopen(NameOfFile, 'rt');
fgets(fpCSV);
lineStr = fgets(fpCSV);
fclose(fpCSV);
in my *.m file. It is actually buried in the method of a class that I wrote.
In interactive mode in Matlab, the script works great. I ran the Application Builder Tool and successfully compiled. However, when I run my application I get "Invalid file identifier" (see attached screenshot). How do I debug this?
Accepted Answer
More Answers (0)
Categories
Find more on Low-Level File I/O in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!