I would like to run an executable from the Matlab command line. However when I try
system('MyProgram.exe')
I get the error,
Unhandled Exception: System.IO.IOException: The handle is invalid.
When MyProgram.exe is run from the Windows command line, it opens a GUI that you enter commands into.
Any suggestions on what is going wrong here?

 採用された回答

KAE
KAE 2019 年 10 月 30 日
編集済み: KAE 2019 年 10 月 30 日

0 投票

Passing along the solution from here in case it helps someone: Due to the popup window that the exe generates, I needed to add an & at the end,
system('MyProgram.exe &')
Then it works fine!

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File Exchange で Introduction to Installation and Licensing についてさらに検索

タグ

質問済み:

KAE
2019 年 10 月 29 日

編集済み:

KAE
2019 年 10 月 30 日

Community Treasure Hunt

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

Start Hunting!

Translated by