Refresh Data under time interval

11 次查看(过去 30 天)
Jeffrey Pang
Jeffrey Pang 2019-4-26
I cannot get this code to run while under this time interval.
I want it so, when a button is pressed, the data will refresh and give me a different output than before
ex.
If time interval is less than half a second, then run code
else
if time interval is greater than half a second, run alternate code
function bool = CheckSlap(hObject, eventdata, handles)
bool = 0;
tic
while toc < 0.5
refreshdata(handles.slap);
if handles.slap == 1
bool = 1;
break;
end
end
end

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Shifting and Sorting Matrices 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by