This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English version of the page.

Note: This page has been translated by MathWorks. Click here to see
To view all translated materials including this page, select Country from the country navigator on the bottom of this page.

matlab.addons.disableAddon

Disable installed add-on

Syntax

matlab.addons.disableAddon(identifier)
matlab.addons.disableAddon(identifier,version)

Description

example

matlab.addons.disableAddon(identifier) disables the installed add-on with the specified identifier. You can disable and enable most add-ons from the MATLAB® user community. Disabling and enabling MathWorks® products and support packages is not supported.

If multiple versions of an add-on are installed, you must specify a version.

example

matlab.addons.disableAddon(identifier,version) disables the installed add-on with the specified identifier and version.

Examples

collapse all

Suppose that you have an add-on called Random File Name Creator installed on your system. Get the list of installed add-ons and disable the Random File Name Creator add-on.

Get the list of installed add-ons.

addons = matlab.addons.installedAddons
 addons =

  1×4 table

             Name                   Version     Enabled                  Identifier              
    ___________________________    _________    _______    ______________________________________

    "Random File Name Creator"     "1.0"         true      "75442144-f751-4011-bm0e-32b6fb2f1433"

Disable Random File Name Creator and confirm that it is disabled.

matlab.addons.disableAddon('75442144-f751-4011-bm0e-32b6fb2f1433')
matlab.addons.isAddonEnabled('75442144-f751-4011-bm0e-32b6fb2f1433')
ans =

  logical

   0

Suppose that you have versions 2.0 and 4.0 of an add-on called My Toolbox installed on your system. Version 4.0 is enabled and version 2.0 is disabled. Disable version 4.0 of the add-on.

Get the list of installed add-ons.

addons = matlab.addons.installedAddons
addons =

  2×4 table

             Name                   Version     Enabled                  Identifier              
    ___________________________    _________    _______    ______________________________________

    "My Toolbox_v4.0"              "4.0"         true      "6de8682e-9c3c-407e-bad7-aa103d738d08"
    "My Toolbox"                   "2.0"         false     "6de8682e-9c3c-407e-bad7-aa103d738d08"

Disable My Toolbox version 4.0 by specifying the first item in the returned list of identifiers. Then, confirm that it is disabled.

matlab.addons.disableAddon(addons.Identifier(1),'4.0')
matlab.addons.isAddonEnabled(addons.Identifier(1),'4.0')
ans =

  logical

   0

Input Arguments

collapse all

Unique identifier of the add-on that you want to disable, specified as a character vector or string. To determine the unique identifier of an add-on, use the matlab.addons.installedAddons function.

Version of the add-on that you want to disable, specified as a character vector or string. To determine the version of an add-on, use the matlab.addons.installedAddons function.

Introduced in R2017b