create copies of the same gui under different tabs
Show older comments
Hello everyone,
I'm new to matlab's app designer and making guis. I have made a gui for plotting a bunch of heatmaps in a way i like them, but during experiments, i need to look at multiple such GUI plots and potentially even combine them into a single plot. Currently I have been opening mulitple instances of the same gui using run xxx, and loading different data into each for their respective plots. I was wondering if I can use something like tabs within a single app window (like a browser), where i can open multiple independent instances of the same GUI (so i can load different data into each tab manually) and also have the ability to share some data across these mutliple instances - say to get an aggregate plot over 2-3 tabs. In other words, I just need help with making multiple copies of the same gui so i can avoid having to rewrite / copy paste multiple call back functions for each tab.
Thanks in advance !!
3 Comments
Michael Van de Graaff
on 20 Apr 2021
Isn't this what the duplicate option does when right clicking in design view? not on the fly, but you can set everything up and then duplicate and app designer automatically generates all the code.
so if i have a tab, in App designer, i go to the designview, find my tab, right click it, and select duplicate. Then a new tab with all the same uicontrols and buttons and boxs and things pops into existence, and appdesigner duplicates all the code, but instead of Mybutton, Myswitch, you get Mybutton_2, MySwitch_2
do it again and get Tab_3 with Mybutton_3 and Myswitch_3.
so if you know you need at most to have 5 seperate datasets and analysis windows, then use the duplicate option to duplicate one tab afer you get it how you like, and all the code should autopopulate. then when you run the app, in the one app, you have five tabs that each do the same thing, independently. But idk if you can then add a new tab super easily to the existing five.
however, I have noticed that App designer can get slow when tabs multiply, i rewrote my image analysis app to pop up its results in new figures that are generated and closed programmatically, and it's much faster, but if you aren't noticing a slow app, then your taskbar real estate may be worth it
Aravind Krishna
on 20 Apr 2021
> I just need help with making multiple copies of the same gui
The goal is unclear. A gui is just a guided/graphical user interface. So it's unclear what you want to copy. It's also unclear why you need to copy something rather than developing it within app designer.
Answers (0)
Categories
Find more on Develop Apps Using App Designer in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!