Is it possible to have a uiconfirm choose an option after a timeout period?
I am trying to modify my uiconfirm popup to select the ‘DefaultOption’ after some time to avoid having the popup open for a long period of time and holding up code execution.
I have already tried using a timer to select one of the options which didn’t seem to work but maybe I did it wrong.
I can explain what I am trying to do and why in further detail if needed.
Here is a barebones example of what I am trying to modify:
closeHdlg = uiconfirm(MainFigure, "Title",’Program’,’Options’,{‘Retry’,’Disconnect’,’Continue’},’DefaultOption’,’Retry’);
switch closeHdlg
case ‘Retry’
% Hidden for confidentiality
case ‘Disconnect’
% Hidden for confidentiality
case ‘Continue’
% Hidden for confidentiality
case ”
% close box and do nothing
end % end switchI am trying to modify my uiconfirm popup to select the ‘DefaultOption’ after some time to avoid having the popup open for a long period of time and holding up code execution.
I have already tried using a timer to select one of the options which didn’t seem to work but maybe I did it wrong.
I can explain what I am trying to do and why in further detail if needed.
Here is a barebones example of what I am trying to modify:
closeHdlg = uiconfirm(MainFigure, "Title",’Program’,’Options’,{‘Retry’,’Disconnect’,’Continue’},’DefaultOption’,’Retry’);
switch closeHdlg
case ‘Retry’
% Hidden for confidentiality
case ‘Disconnect’
% Hidden for confidentiality
case ‘Continue’
% Hidden for confidentiality
case ”
% close box and do nothing
end % end switch I am trying to modify my uiconfirm popup to select the ‘DefaultOption’ after some time to avoid having the popup open for a long period of time and holding up code execution.
I have already tried using a timer to select one of the options which didn’t seem to work but maybe I did it wrong.
I can explain what I am trying to do and why in further detail if needed.
Here is a barebones example of what I am trying to modify:
closeHdlg = uiconfirm(MainFigure, "Title",’Program’,’Options’,{‘Retry’,’Disconnect’,’Continue’},’DefaultOption’,’Retry’);
switch closeHdlg
case ‘Retry’
% Hidden for confidentiality
case ‘Disconnect’
% Hidden for confidentiality
case ‘Continue’
% Hidden for confidentiality
case ”
% close box and do nothing
end % end switch matlab gui, uiconfirm, timeout MATLAB Answers — New Questions