Reading a multi line string into a single string
Mostra commenti meno recenti
I have opened a file with a string consisting of three lines. I want to read these lines from the file and store them in my "template" variable as a three line string. All I can get is the last line of the string to be stored in "template"
while feof(fid) == 0;
line = fgets(fid);
template = strvcat(line)
end
Thanks for the help
Risposta accettata
Più risposte (1)
Matt Tearle
il 19 Mar 2011
0 voti
Categorie
Scopri di più su File Operations in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!