フィルターのクリア

multiple actions following @(src,event) in uicontrol

3 ビュー (過去 30 日間)
feynman feynman
feynman feynman 2024 年 3 月 10 日
コメント済み: Voss 2024 年 3 月 10 日
How to add another action or function to the following
Button=uicontrol('Style','pushbutton', 'String','pause','Position',[1800 60 100 100], 'Callback',@(src,event)continue);
so that it becomes sth like
Button=uicontrol('Style','pushbutton', 'String','pause','Position',[1800 60 100 100], 'Callback',@(src,event){continue,close});

採用された回答

Voss
Voss 2024 年 3 月 10 日
Define a function that has whatever code in it you want.
Then make that function the button's callback:
Button=uicontrol('Style','pushbutton', 'String','pause','Position',[1800 60 100 100], 'Callback',@(src,event)your_function);
  4 件のコメント
feynman feynman
feynman feynman 2024 年 3 月 10 日
perfect, thanks
Voss
Voss 2024 年 3 月 10 日
You're welcome!

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

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeMigrate GUIDE Apps についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by