frewind
Set position of stream to the beginning.
📝Syntax
frewind(fid)
📥Input Arguments
Parameter Description
fid an integer value: file descriptor
📄Description

frewind puts the pointer at the beginning of file

💡Examples
fileID = fopen([tempdir(), 'frewind.txt'],'wt');
fprintf(fileID, 'son is beautiful.');
frewind(fileID);
fprintf(fileID, 'sun');
fclose(fileID);
R = fileread([tempdir(), 'frewind.txt'])
🔗See Also
fclose
🕔Version History
Version Description
1.0.0 initial version
Edit this page on GitHub