waitfordata

版本 1.0.0.0 (2.2 KB) 作者: Peter Li
Block Matlab while specified fig is open, then grab APPDATA when fig is closing.
207.0 次下载
更新时间 2012/9/13

查看许可证

Imagine you have a GUI that saves some data you want in an APPDATA field named 'points'. You can get that field using: getappdata(f, 'points'), but this gives you no guarantee that the user is actually done with the GUI; you don't know if POINTS is in a finished state yet.

If you instead run: data = waitfordata(f, {'points'}); points = data{1}, you now block execution until the GUI is closed, but grab the points data from the GUI just as it is closing. You have a guarantee that points will be set with the data only after the user finished with the GUI.

引用格式

Peter Li (2024). waitfordata (https://www.mathworks.com/matlabcentral/fileexchange/38160-waitfordata), MATLAB Central File Exchange. 检索来源 .

MATLAB 版本兼容性
创建方式 R2012a
兼容任何版本
平台兼容性
Windows macOS Linux
类别
Help CenterMATLAB Answers 中查找有关 View and Analyze Simulation Results 的更多信息
标签 添加标签
gui

Community Treasure Hunt

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

Start Hunting!
版本 已发布 发行说明
1.0.0.0