how to get the specific model name/ extention(.mdl) from a folder which has count less depths?
3 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Sudhakar Akki
am 17 Sep. 2016
Kommentiert: Sudhakar Akki
am 22 Sep. 2016
i would like to extract the *.sldd and *.h files from the folder which has multiple levels. example: folder X has X1,X2folders, X1 has Y1, Y2 and Y3 folders and Y2 has Z1,Z2 folders. Z2 folder contains some test.h file and Z1 contains some data.sldd
is there API to sort out the required file names based on extention?
0 Kommentare
Akzeptierte Antwort
Jordan Ross
am 21 Sep. 2016
Hi Sudhakar,
In MATLAB R2016b you can use the "dir" function as follows:
>> list = [dir('**/*.sldd'); dir('**/*.h')]
The variable "list" will then contain a vector of structures which correspond to the files with the extensions .SLDD and .H.
For more information about the "dir" function see: http://www.mathworks.com/help/matlab/ref/dir.html
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu File Operations 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!