Main Content

slreq.openRequirementsManager

Open Requirements Manager app in model

Since R2021a

    Description

    example

    slreq.openRequirementsManager(model) opens the Requirements Manager app in the Simulink® model model and brings the model to the front. The model must be open.

    Examples

    collapse all

    This example shows how to open and close the Requirements Manager app programmatically.

    Open the CruiseRequirementsExample project and open the crs_plant model.

    openProject("CruiseRequirementsExample");
    open_system("crs_plant");

    Open the Requirements Manager app in the crs_plant model.

    slreq.openRequirementsManager("crs_plant");

    Close the Requirements Manager app in the crs_plant model.

    slreq.closeRequirementsManager("crs_plant");

    Input Arguments

    collapse all

    Simulink model to open the Requirements Manager app in, specified as a string scalar or character vector that contains the name of the model, or a model handle.

    Tips

    • Use bdroot (Simulink) to get the top-level model of the current system.

    • Use get_param (Simulink) and bdroot (Simulink) to get the handle for the top-level model of the current system:

      model = get_param(bdroot,"Handle");

    • Open the Requirements Editor with slreq.editor.

    Version History

    Introduced in R2021a