How to wait a keypress?

回答 (1 件)

Stephen23
Stephen23 2015 年 4 月 20 日
編集済み: Stephen23 2015 年 4 月 20 日

0 投票

You can use pause to achieve this.

2 件のコメント

Mr M.
Mr M. 2015 年 4 月 20 日
No, no! I would like to wait a specific character! For example pressing "a" to doing something and pressing "b" to do something else!
Stephen23
Stephen23 2015 年 4 月 20 日
編集済み: Stephen23 2015 年 4 月 20 日
Then you could try using input, and calling switch with the value that the user inputs.

サインインしてコメントする。

カテゴリ

ヘルプ センター および File ExchangeLoops and Conditional Statements についてさらに検索

質問済み:

2015 年 4 月 20 日

編集済み:

2015 年 4 月 20 日

Community Treasure Hunt

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

Start Hunting!

Translated by