Creation of Simulink Libraries
2 views (last 30 days)
I have created a Simulink library but the library I created is linked to its block. I want to have it such a way that all the blocks which I am using in a model from this lib must be unlinked. So that any further change either in Model block or Library should not have any effect on each other.
It should be in such a way that it's block should be unlinked from the library the moment it is used in a model.
Hope to hear from you guys soon.
Sebastian Castro on 8 Apr 2015
Edited: Sebastian Castro on 8 Apr 2015
Yes, you can do this.
When you drag a block in from a library, it essentially copies and pastes it into your new model. So, the key is to programmatically disable the library link when this block is copied.
To do this, you can right-click your block and go to Properties. Then, go to the Callbacks tab. Then, add the following line to your CopyFcn callback:
Does this work?