Quantcast

Documentation Center

  • Trial Software
  • Product Updates

Simulink.ModelManagement.Project.CurrentProject.isProjectLoaded

Class: Simulink.ModelManagement.Project.CurrentProject
Package: Simulink.ModelManagement.Project

(To be removed) Return true when a Simulink project is loaded and false when no project is loaded

    Note:   Simulink.ModelManagement.Project.CurrentProject.isProjectLoaded will be removed in a future release. Use isLoaded instead.

Syntax

p = Simulink.ModelManagement.Project.CurrentProject()
isLoaded = p.isProjectLoaded

Description

p = Simulink.ModelManagement.Project.CurrentProject() creates an instance of the CurrentProject class.

isLoaded = p.isProjectLoaded returns 1 or 0 depending on whether a Simulink project is loaded or not loaded, respectively.

Example

To determine if a Simulink project is loaded, use the following commands.

  1. Create an instance of the CurrentProject class.

    p = Simulink.ModelManagement.Project.CurrentProject();
  2. Use the isProjectLoaded method.

    isLoaded = p.isProjectLoaded;

    isLoaded = 0 indicates that no Simulink project is loaded

    isLoaded = 1 indicates a Simulink project is loaded

See Also

Was this topic helpful?