In app designer, How to use global variables from m file?
1 次查看(过去 30 天)
显示 更早的评论
As I say, I made a "m file" that contains global variables for using in various kinds of windows(I mean apps or functions).
And also made another "m file" for function that read a file then store data in global variables which I described.
I can call the file read function but I don't know how to call the global variables in app designer.
Anybody know how to call them?
0 个评论
回答(1 个)
Jae Heon Kim
2020-1-16
2 个评论
Matthias De Lepeleer
2021-5-7
Facing the same problem here, what do you mean by you can arrange it?
I declared global variables in my m-file (script) and want to display those variables in the app desiger. I tried several ways. None is working.
% Run script (m-file)
m-filename
% Call global from m-file ('switch_ui' is the global var)
global switch_ui;
app.SwitchesEditField.Value = switch_ui;
yan m
2022-2-1
Hello i want to do the opposite of this, call my
AppDesignerVariable into a .m file that will start by :
Var = AppDesignerVariable;
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Develop Apps Using App Designer 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!