Why does FPRINTF return an error when the file identifier 0 is specified in MATLAB 7.3 (R2006b)?
Show older comments
The FPRINTF function returns an error if the fid value is specified as 0 in MATLAB 7.3 (R2006b). In previous releases we have used a file identifier value of 0 when it was necessary to suppress printing to the command window.
fprintf(1, 'I use this to supress printing to the Command Window\n')
produces an output:
I use this to supress printing to the Command Window
However, the statement:
fprintf(0, 'I use this to supress printing to the Command Window\n')
produces the following error:
??? Error using ==> fprintf
Operation is not implemented for requested file identifier.
Accepted Answer
More Answers (0)
Categories
Find more on Desktop 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!