Add Method (AddIns Collection) Example

This example inserts the add-in Myaddin.xla from drive A. When you run this example, Microsoft Excel copies the file A:\Myaddin.xla to the Library folder on your hard disk and adds the add-in title to the list in the Add-Ins dialog box.

Set myAddIn = AddIns.Add(Filename:="A:\MYADDIN.XLA", _
        CopyFile:=True)
MsgBox myAddIn.Title & " has been added to the list"