removeReference

(Not recommended) Add folder to project path

simulinkproject is not recommended. Use currentProject or openProject instead. For more information, see Compatibility Considerations.

Description

example

removeReference(project,folder) removes the reference to the project project from the current project.

Examples

collapse all

Create a project and get a project object.

sldemo_slproject_airframe;
project = simulinkproject;

Create a new blank project.

projectToReference = slproject.create();

Reload the first project and add a reference to the new blank project.

 project.reload();
addReference(project, projectToReference, 'absolute');

Remove the reference to the blank project.

removeReference(project, projectToReference);

Input Arguments

collapse all

Project, specified as a project object. Use simulinkproject to create a project object to manipulate a project at the command line.

Path of the folder to the reference to be removed, relative to the project root folder, specified as a character vector. The folder must be within the root folder.

Example: models/myfolder

Compatibility Considerations

expand all

Not recommended starting in R2019a

Introduced in R2017a