Command to show open a Simulink model and focus on a specific block

删除回忆录丶 提交于 2019-12-11 10:46:22

问题


I've got a long list of comments in a separate document that refer the named subsystem blocks within a Simulink model. I'm going to process the document with a script that will generate a browser-viewable page, with each block name clickable - such that when you click on the block name, Matlab will launch using a CLI command, and display the model which the comment refers to.

The document generation and shell function call is all working, but I can't find a command that will centre on a specific block. I'm looking for a type of "find/search" function to centre the view on a specified block, once the model has been opened using a standard open command from the command-line.

I suspect that it might not be possible, but worth asking. Any ideas?

Thanks


回答1:


Use the hilite_system command. For example:

hilite_system( 'myModel/Path/to/my/block' );

The selected block is also highlighted, you can use the optional second parameter to remove highlighting, or customize it, if desired.



来源:https://stackoverflow.com/questions/6252873/command-to-show-open-a-simulink-model-and-focus-on-a-specific-block

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!