concatenate multiple files listed in ListBox using PushButton
6 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
PF
am 1 Okt. 2015
Beantwortet: Walter Roberson
am 1 Okt. 2015
Hi I have imported and listed multiple files in listbox (e.g.3 files, fullpath and filename are listed e.g.'C:\Users\file1.mat'). By clicking on the pushbutton, 3 listed files shall be concatenated to a single files.
for i=1:3
fileimportpath(i)= get(handles.listbox3,'String');
fid=fopen(fileexportpath,'a');
fprintf(fid,'%4.3f %2.5f %2.5f\r\n',A,B,C);
end
fclose('all');
Currently, this script encountered problem in reading the 'fileimportpath'. May I know what is the solution for it?
Thanks!
0 Kommentare
Akzeptierte Antwort
Walter Roberson
am 1 Okt. 2015
fileimportpath = get(handles.listbox3, 'String');
for i = 1 : 3
fid = fopen(fileimportpath{i}, 'a');
fprintf(fid,'%4.3f %2.5f %2.5f\r\n',A,B,C);
fclose(fid);
end
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Migrate GUIDE Apps finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!