How to list files in the directory

조회 수: 65 (최근 30일)
Ompilela Tshikosi
Ompilela Tshikosi 2020년 5월 27일
댓글: Stephen23 2020년 5월 27일
How do i list file with certain prefix for instance file that include 'Data' in the directory and of certain type for instance only excel file ('.xlsx')

채택된 답변

Stephen23
Stephen23 2020년 5월 27일
D = 'absolute/relative path to where the files are saved';
S = dir(fullfile(D,'Data*.xlsx'))
  댓글 수: 2
Ompilela Tshikosi
Ompilela Tshikosi 2020년 5월 27일
Thank you. It worked
Stephen23
Stephen23 2020년 5월 27일
@Ompilela Tshikosi : I hope that it helped. Please remember to accept my answer!

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 File Operations에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by