Azzera filtri
Azzera filtri

How can I use following code to select .txt files instead of .m file

2 visualizzazioni (ultimi 30 giorni)
[files,path] = uigetfile('MultiSelect', 'on');
if iscell(files)
for n = 1:length(files)
data = importdata(fullfile(path,files{n})); % fullfile including path
% save data
end
else
data = importdata(fullfile(path,files));
% save data
end

Risposta accettata

Yongjian Feng
Yongjian Feng il 18 Ott 2021
Follow this link, you can set the filter:
```
[file,path] = uigetfile({'*.m';'*.slx';'*.mat';'*.*'},...
'File Selector');
```

Più risposte (0)

Categorie

Scopri di più su MATLAB in Help Center e File Exchange

Prodotti

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by