I have a problem with appdesigner, can you help me?
1 visualización (últimos 30 días)
Mostrar comentarios más antiguos
Hello everyone.
I have a problem with appdesigner.
I have created two GUI, in the first GUI random images are displayed in time, the latter is taken from input, in the second GUI a questionnaire is made, I would like to send the data of this questionnaire to the first gui. But I can't, can you help me?
0 comentarios
Respuestas (2)
chicken vector
el 8 de Abr. de 2023
Editada: chicken vector
el 8 de Abr. de 2023
I must say that is really hard to help you with so little infromation.
If you don't need real time sharing you can pass the data with save and load using .mat files.
Otherwise, if you need real time sharing, AppDesigner is not so beginner-friendly.
To share data between two different .mlapp files you have to use properties.
If App1 is the main window, you can create a property in it that works as instance handle of App2.
For example, in the initialising function createComponents you can define the property
app1.app2Handle = App2;
Using property allow to have save in the first app class the isntance of the second app, granting permanent acces to its data and features. If you need the data only once you don't have to use properties,
What I like to do instead, is do develop the multi-GUI app in one code. You can create as many instances of UIFigure as you want inside the class instance app (app.UIFigure, app.UIFigure1, ...) and manage their existance and visibility with events. With this approach I usually build the GUI in AppDesigner and copy-paste everything for the Code view in a script to do the programmin part, to have more freedom and avoid greyed out code. You can find an example here.
0 comentarios
Ver también
Categorías
Más información sobre Develop Apps Using App Designer 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!