Project File Management

Search, label, batch process, share, and upgrade project files, and create scripts

Projects help you to organize large modeling projects by finding required files, managing and sharing files and settings, and interacting with source control. See What Are Projects?.

Functions

expand all

currentProjectGet current project
openProjectLoad an existing project
addFileAdd file or folder to project
addFolderIncludingChildFilesAdd folder and child files to project
addLabelAttach label to project file
addPathAdd folder to project path
addReferenceAdd referenced project to project
addShortcutAdd shortcut to project
closeClose project
createCategoryCreate category of project labels
createLabelCreate project label
exportExport project to archive
findCategoryFind project category of labels
findFileFind project file by name
findLabelGet project file label
isLoadedDetermine if project is loaded
reloadReload project
removeCategoryRemove project category of labels
removeLabelRemove label from project

Legacy API

simulinkproject(Not recommended) Open project and get project object
slproject.loadProject(Not recommended) Load project
slproject.getCurrentProjects(Not recommended) List all top-level projects
addFile(Not recommended) Add file to project
addFolderIncludingChildFiles(Not recommended) Add folder and child files to project
addLabel(Not recommended) Attach label to project file
addPath(Not recommended) Add folder to path of project
addReference(Not recommended) Add referenced project to project
addShortcut(Not recommended) Add shortcut to project
close(Not recommended) Close project
createCategory(Not recommended) Create category of project labels
createLabel(Not recommended) Define project label
export(Not recommended) Export project to zip
findCategory(Not recommended) Get project category of labels
findFile(Not recommended) Get project file by name
findLabel(Not recommended) Get project file label
isLoaded(Not recommended) Determine if project is loaded
reload(Not recommended) Reload project
removeCategory(Not recommended) Remove project category of labels
removeLabel(Not recommended) Remove label from project

Examples and How To

Scripting

Automate Simulink Project Tasks Using Scripts

Use the project API to automate project tasks manipulating files, including working with modified files, dependencies, shortcuts, and labels.

Frequent Tasks

Open Recent Projects

Open recent projects from MATLAB® or Simulink®.

Create Shortcuts to Frequent Tasks

In a project, create shortcuts for common project tasks and to make it easy to find and access important files and operations.

Use Shortcuts to Find and Run Frequent Tasks

In a project, use shortcuts to make it easy for any project user to find and access important files and operations.

File Management

Group and Sort File Views

Control list or tree view columns and hide folders in project file views.

Search Inside Project Files and Filter File Views

Search inside models and other files across your project, and filter files to display.

Work with Project Files

Access common file operations using the context menu in a project.

Manage Shadowed and Dirty Models and Other Project Files

Avoid working on the wrong files using project tools, check for unsaved changes in models, and close models when closing a project.

Move, Rename, Copy, or Delete Project Files

Project refactoring tools help you find and fix impact with automatic updates when you rename, delete, or move files and folders.

Back Out Changes

Undo recent changes in a project.

File Labels

Create Labels

In a project, use labels to organize files and communicate information to project users.

Add Labels to Files

In a project, use labels to organize files and communicate information to project users.

View and Edit Label Data

When you select a file in the project Files view, the file labels appear in the label editor view.

Custom Task Processing

Create a Custom Task Function

Create functions and run them on selected project files.

Run a Project Custom Task and Publish Report

Run a function on selected project files, view results, and create a report of the results.

Sharing Projects

Archive Projects

Package and share project files in an archive file, for example to share with others who do not have access to the connected source control tool.

Share Project by Email

To package and share project files on Windows®, you can email your project as a an archive file.

Share Project as a MATLAB Toolbox

To package and share project files, create a MATLAB toolbox from your project.

Share Project on GitHub

To share your project, make your project publicly available on GitHub®.

Upgrade Projects

Upgrade All Project Models, Libraries, and MATLAB Code Files

Upgrade all the models, libraries and MATLAB code files in your project using the Upgrade Project tool in a project.

Concepts

What Are Projects?

Use projects to help you organize your work. Find all your required files; manage and share files, settings, and user-defined tasks; and interact with source control.

What Can You Do With Project Shortcuts?

In a project, use shortcuts to make it easy for any project user to find and access important files and operations.

Sharing Projects

Collaborate by sharing projects by email, archive file, template, MATLAB toolbox, or on GitHub.

Featured Examples