Class AddIn (Excel VBA)

The class AddIn represents a single add-in, either installed or not installed. To use a AddIn class variable it first needs to be instantiated, for example


Dim adi as AddIn
Set adi = AddIns(Index:=1)

For Each

Here is an example of processing the AddIn items in a collection.


Dim adi As AddIn
For Each adi In AddIns
    adi.FullName
Next adi

CLSID

Returns a read-only unique identifier, or CLSID, identifying an object as a String.


Dim strCLSID As String
strCLSID = AddIns(1).CLSID

FullName

Returns the name of the object, including its path on disk, as a string.


Dim strFullName As String
strFullName = AddIns(1).FullName

Installed

True if the add-in is installed or to install the add-in; False if the add-in is uninstalled or to uninstall the add-in.

Setting this property to True installs the add-in and calls its Auto_Add functions. Setting this property to False removes the add-in and calls its Auto_Remove functions.


AddIns(1).Installed = True

IsOpen

Returns True if the add-in is currently open.


Dim booIsOpen As Boolean
booIsOpen = AddIns(1).IsOpen

Name

Returns a String value that represents the name of the object.


Dim strName As String
strName = AddIns(1).Name

Path

Returns a String value that represents the complete path to the Add-in, excluding the final separator and name of the Add-in.


Dim strPath As String
strPath = AddIns(1).Path

progID

Returns the programmatic identifiers for the object.


Dim strprogID As String
strprogID = AddIns(1).progID