Info
此问题已关闭。 请重新打开它进行编辑或回答。
How can I migrate a model reference hierarchy to use a common data dictionary programatically?
7 次查看(过去 30 天)
显示 更早的评论
How can I migrate a model reference hierarchy to use a common data dictionary programatically?
To migrate a single model I can use:set_param(modelName,'DataDictionary',dictionaryName);
To migrate a model reference hierarchy I can go to the Model Properties dialog box -> Data, and select Data Dictionary. A message will be shown asking if I want to migrate referenced variables from base workspace to the same dictionary. I’m looking for a way to do this programatically.
Thank you
0 个评论
回答(1 个)
Mark McBroom
2018-6-28
编辑:Mark McBroom
2018-6-28
use
mdlList = find_mdlrefs(modelName);
for i=1:numel(mdlList)
set_param(mdlList{i},'DataDictionary',dictionaryName);
end
0 个评论
此问题已关闭。
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!