I would like to create a for loop with start, pause , continue and cancel push buttons on guide.

1 回表示 (過去 30 日間)
Atacan Tosun
Atacan Tosun 2016 年 12 月 8 日
回答済み: Image Analyst 2016 年 12 月 8 日
START should execute the loop -PAUSE should stop the loop-CONTINUE should resume from where left after pausing-CANCEL should terminate the loop or program
The thing is I could not connect pushbuttons with loop. how to declare variables which will be use in main function and how to call them.
for i=0:100
disp(i);
end
"PushStart" 0 1 2 3 "PushPause"------------- "PushContinue" 4 5 6 7 8---------- "PushStop"---------- terminate
  3 件のコメント
Atacan Tosun
Atacan Tosun 2016 年 12 月 8 日
I could not connect pushbuttons with loop.
Jan
Jan 2016 年 12 月 8 日
編集済み: Jan 2016 年 12 月 8 日
@Atacan: How did you try it? Please post your code, even if it does not work currently, and ask a specific question. Give us a chance to assist you. E.g. there is simply no "pusbutton" in your code, so how could it be "connected"? Therefore a solution must start with the trivial: "Create a pushbutton".

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

回答 (1 件)

Image Analyst
Image Analyst 2016 年 12 月 8 日
See attached button that creates a Go/Stop situation. Press the Go button to start a counting process. Click the Step button to stop it.

カテゴリ

Help Center および File ExchangeLoops and Conditional Statements についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by