app.UIfigure.Visible does not keep the app window on top of all other windows

1 visualización (últimos 30 días)
Hi all
using the following line does not really keep the app window in appdesigner on top of all other windows , I have two pushbuttons and for each, the window should remain on top:
app.UIFigure.Visible = 'on';

Respuesta aceptada

Cris LaPierre
Cris LaPierre el 21 de Mzo. de 2020
Editada: Cris LaPierre el 21 de Mzo. de 2020
Try using drawnow with the figure command in your button callbacks (see this post)
drawnow;
figure(app.UIFigure)
  10 comentarios
farzad
farzad el 24 de Mzo. de 2020
Thank you Cris, but I got an error
Undefined function 'FocusUIFigure' for input arguments of type 'matlab.ui.Figure'.
Error in app120/ChooseDirectoryButtonPushed (line 27)
FocusUIFigure(app.UIFigure)
Error using matlab.ui.control.internal.controller.ComponentController/executeUserCallback (line 309)
Error while evaluating Button PrivateButtonPushedFcn.
Cris LaPierre
Cris LaPierre el 24 de Mzo. de 2020
FocusUIFigure is a custom function that is attached to the post I linked you to. You'll have to download it in order to use it.

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre App Building en Help Center y File Exchange.

Community Treasure Hunt

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

Start Hunting!

Translated by