How to Save All App Designer Fields and Values data in to .mat file ?

22 vues (au cours des 30 derniers jours)
Anup Patil
Anup Patil le 21 Juil 2023
Modifié(e) : Pratyush le 24 Juil 2023
Hi,
I am Developing an Application where some Configuration we are setting that same configuration I need to save and if Needed I can Import that in Application , Is there any way to Save All Variables (Values , Fields etc.. ) Will be save in .mat file and restore them ?

Réponse acceptée

Pratyush
Pratyush le 24 Juil 2023
Modifié(e) : Pratyush le 24 Juil 2023
Hi Anup,
I understand that you want to save the confiuration of your app and restore it when required the next time. A similar question has been answered in the following link: How to save/restore state of App Designer app? This could be acheived programatically in the following way :-
  • To save the configuration add the following code to any function using which you want to save the configuration:
B= app.DataPointsEditField.Value;
save("config.mat", 'B');
  • To restore the configuration add the following code to the function using which you want to restore the configuration:
load("config.mat");
app.DataPointsEditField.Value = B;

Plus de réponses (0)

Catégories

En savoir plus sur Develop Apps Using App Designer dans Help Center et File Exchange

Produits


Version

R2023a

Community Treasure Hunt

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

Start Hunting!

Translated by