title: Close/Delete uiprogressdlg of Matlab AppDesigner on error
body: <p>I want to know how to close the &quot;waitbar&quot; equivalent of the AppDesigner called &quot;uiprogressdlg&quot; when an error happend inside any callback-functions.</p>
  <p>I dont want to implement any try-catch-elements.</p>
  <p>I tried to use the &quot;KeyPressFcn&quot;, &quot;WindowKeyPressFcn&quot;, &quot;SizeChangedFcn&quot;. But they only work, when there is no uiprogressdlg-box running.</p>
  <p>I can't get the uiprogressdlg-handle with evalin('base','app'). In my case i use &quot;app.PB = uiprogressdlg(app.GUIname,....) and &quot;PB&quot; is a public property of &quot;app&quot;.</p>
  <p>UseCase: While using and debugging the app, i dont want to do a complete app-restart, when this happens, but right now, thats the only solution to close the uiprogressdlg-box.</p>