dir search multiple files

12 visualizaciones (últimos 30 días)
Lana
Lana el 19 de Sept. de 2011
Comentada: Steve Grobler el 9 de Mzo. de 2018
Hello,
I am using the dir command to search a folder for specific file types. I am looking for both *.jpg and *.png files. How do I structure my statement so that I can search for both file types?

Respuestas (1)

Fangjun Jiang
Fangjun Jiang el 19 de Sept. de 2011
Files=[dir('*.jpg');dir('*.png')]
  3 comentarios
Michael
Michael el 10 de Sept. de 2014
I know this is an old link, but it totally saved me. Thanks!
Steve Grobler
Steve Grobler el 9 de Mzo. de 2018
helped me too!!

Iniciar sesión para comentar.

Categorías

Más información sobre File Operations en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by