필터 지우기
필터 지우기

How to run all the external files with same extension .bat within the same folder in MATLAB r2018b

조회 수: 1 (최근 30일)
Hello,
I would like to run all the external files with the extension .bat within the folder c:\t, in MATLAB. The command must be given in a general way, because the name of the files are not the same everytime. How can I do it? I tried dos(c:\t\*.bat), but it does not seem to work. I am using MATLAB r2018b
Can anyone help me?
I thank you in advance,
Best regards,
Hugo

채택된 답변

Rik
Rik 2020년 10월 28일
편집: Rik 2020년 10월 28일
Use dir to create a list of all the bat files. Then you can use either dos or system to run each of them in a for loop.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Startup and Shutdown에 대해 자세히 알아보기

태그

제품


릴리스

R2018b

Community Treasure Hunt

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

Start Hunting!

Translated by