Hi there, I would like to launch a .bat file from matlab at the bat file direcetry

4 Ansichten (letzte 30 Tage)
I am using the following commands:
system('.\VFPSolver\runvfph.bat &'); and it works, but point to the matlab directory. I would like to let Matlab execute bat file at the bat file directory. Any suggestions?

Akzeptierte Antwort

Jan
Jan am 31 Okt. 2018
Bearbeitet: Jan am 31 Okt. 2018
Maybe you mean.
cd('.\VFPSolver\');
system('runvfph.bat &');
  2 Kommentare
Davide Di Pasquale
Davide Di Pasquale am 31 Okt. 2018
Thanks, but when the bat file (inside there is an executable) finish running, it generates same files that I would like to copy on a Folder. But using the command inside the matlab script: copyfile *.force Outputs I got an error Error in run_solver (line 7) copyfile *.force Outputs because of course the excutable did not finish yet. How to say matlab to wait until the run is completed?

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (0)

Kategorien

Mehr zu File Operations finden Sie in Help Center und File Exchange

Tags

Produkte


Version

R2017b

Community Treasure Hunt

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

Start Hunting!

Translated by