how to add a substructure to a structure from app designer
1 次查看(过去 30 天)
显示 更早的评论
Hello
I have a structure in the base workspace(PVGEN.a, PVGEN.b). When I run an app designer application, I would like to add a substructure to this structure (PVGEN.a, PVGEN.b, PVGEN.OPTIONS.c, PVGEN.OPTIONS.d). I can make the OPTIONS structure in the app designer application. The only problem is to add the structure to the existing structure in the base workspace.
Can anyone help me please?
I look out to your answers!
0 个评论
采纳的回答
Chris Portal
2017-4-30
Ideally, you would pass PVGEN into the app for it to work on, and then the app would return it via a method when it's needed. Otherwise, you have to use a mix of ASSIGNIN and EVALIN. Something like:
options.c = 3;
options.d = 4;
assignin('base', 'options', options);
evalin('base', 'PVGEN.OPTIONS = options;');
0 个评论
更多回答(0 个)
另请参阅
类别
在 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!