Multiplying panels using a spinner

3 visualizaciones (últimos 30 días)
Georgiana Cristea
Georgiana Cristea el 19 de Oct. de 2021
Respondida: Mario Malic el 20 de Oct. de 2021
Hello!
I am currently trying to multiply the numbers of panels shown in App designer using a spinner. For example, if the spinner value is two, i want two panels on top of each other to be shown. I also want if possible to switch through them using a forward button and a backwards button.
I will post a picture of my app.
Thank you in advance for helping!
  2 comentarios
Mario Malic
Mario Malic el 19 de Oct. de 2021
two panels on top of each other to be shown is not clear. Maybe Tab Group component is what you mean?
Georgiana Cristea
Georgiana Cristea el 20 de Oct. de 2021
Yes, this would work too!

Iniciar sesión para comentar.

Respuestas (1)

Mario Malic
Mario Malic el 20 de Oct. de 2021
Hi,
You can do that using the Value property of the Spinner component and SelectedTab property of the GroupTab component.
SelectedTab accepts Tab object, and to get that you can use Children component of the TabGroup. Make sure your spinner is in range of children objects (number of tabs)
Example:
% Spinner callback
function SpinnerValueChangedFcn(source,event)
app.GroupTab.SelectedTab = app.GroupTab.Children(event.Value);
end

Categorías

Más información sobre Migrate GUIDE Apps en Help Center y File Exchange.

Productos


Versión

R2019a

Community Treasure Hunt

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

Start Hunting!

Translated by