display text when running exe in dos command window

조회 수: 1 (최근 30일)
Lijun Zou
Lijun Zou 2023년 2월 6일
댓글: Walter Roberson 2023년 2월 7일
After upgrading from Matlab 2015a to Matlab 2022a, I noticed that disp() function does not print anything when running the exe in dos command window. I want to see the display so I know the progress. How can I see the display again?
function dispTest
x = 5;
disp(x)
end

채택된 답변

Walter Roberson
Walter Roberson 2023년 2월 6일
When you compile use the -m option; in particular do not use the -e option.
  댓글 수: 2
Lijun Zou
Lijun Zou 2023년 2월 7일
I use deploytool to compile. I unchecked 'Do not require Windows Command Shell' in the Additional Runtime Settings and I got the number 5 when running the updated exe in DOS command window. I will look into the mcc command. Thanks for your help.
Walter Roberson
Walter Roberson 2023년 2월 7일
The deploytool option you unchecked should be the same as using the -m option.

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

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 MATLAB Compiler SDK에 대해 자세히 알아보기

태그

제품


릴리스

R2022a

Community Treasure Hunt

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

Start Hunting!

Translated by