Main Content

slDestroyToolstripComponent

Destroy Simulink Toolstrip component

Since R2021b

Description

slDestroyToolstripComponent(component) destroys the specified Simulink® Toolstrip component and removes the component directory from the MATLAB® search path. The component directory is the directory that contains the resources subdirectory.

example

slDestroyToolstripComponent(component,Unregister=false) destroys the specified Simulink Toolstrip component, but does not remove the component directory from the MATLAB search path. When Unregister is set to true, the command removes the component directory from the MATLAB path.

Examples

collapse all

Suppose you have a Simulink Toolstrip component that you no longer need named custom.

Destroy the component named custom. In the MATLAB Command Window, enter:

slDestroyToolstripComponent("custom")

Input Arguments

collapse all

Component name, specified as a character vector or string scalar.

The component name appears in the sl_toolstrip_plugins.json file as the value for the "Name" property. Do not edit this file.

Example: slDestroyToolstripComponent("custom")

Data Types: char | string

Option to remove the component directory from the MATLAB search path, specified as a numeric or logical 1 (true) or 0 (false).

Example: slDestroyToolstripComponent("custom",Unregister=false)

Data Types: logical

Version History

Introduced in R2021b