slLoadedToolstripComponents
Description
returns
the name, path, and persistence of loaded custom Simulink® Toolstrip components. components
= slLoadedToolstripComponents
Examples
Remove Custom Tab by Finding Loaded Custom Simulink Toolstrip Components
Suppose you have a custom tab that you want to remove from the Simulink Toolstrip.
Find the loaded custom Simulink Toolstrip components. In the MATLAB® Command Window, enter:
components = slLoadedToolstripComponents
components = 1×2 struct array with fields: name path persisted
The function finds two loaded components.
Get information about the first component.
components(1)
ans = struct with fields: name: 'tools' path: 'B:\path\components\tools' persisted: 0
The function returns the name (tools
), path
(B:\path\components\tools
), and persistence (0
)
of the component. This component does not persist across MATLAB sessions.
Get information about the second component.
components(2)
ans = struct with fields: name: 'custom' path: 'B:\path\customtab' persisted: 1
The function returns the name (custom
), path
(B:\path\customtab
), and persistence (1
) of the
component. This component persists across MATLAB sessions.
Inspect the JSON files in the B:\path\customtab\resources\json
folder of the second component to determine whether the second component defines the
custom tab you want to remove. Also check whether the component defines custom tabs that
you want to keep.
Remove the custom tab by performing one of these actions:
Remove the parent folder of the
resources
folder from the MATLAB path.Stop the custom Simulink Toolstrip component from persisting across MATLAB sessions by using the
slPersistToolstripComponent
function.Rename the
resources
folder to prevent it from being found.Edit the JSON file that defines the custom tab.
Destroy the custom Simulink Toolstrip component using the
slDestroyToolstripComponent
function.
Then, reload the toolstrip configuration.
slReloadToolstripConfig;
Output Arguments
components
— Name, path, and persistence of loaded components
structure array
Name, path, and persistence of loaded components, returned as a structure array.
Version History
Introduced in R2021b
MATLAB Command
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window. Web browsers do not support MATLAB commands.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)
Asia Pacific
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 日本Japanese (日本語)
- 한국Korean (한국어)