COMAddin Object Example

The following routine loops through the list of COMAddins and displays its relevant information in a table on Sheet1 of the workbook containing the code:

Sub COMAddinInfo()

Dim lRow As Long Dim oCom As COMAddIn

' Set up the headings on Sheetl of this workbook With Sheet1.Range("A1:D1") .Value = Array("Guid", "ProgId", .Font.Bold = True .HorizontalAlignment = xlCenter End With

"Creator", "Description"

' Loop through the COMAddins collection and place ' its information in cells below the headings If Application.COMAddIns.Count Then For Each oCom In Application.COMAddIns

With Sheet1.Range("A2")

.Offset(lRow, .Offset(lRow, .Offset(lRow, .Offset(lRow,

.Value .Value .Value .Value lRow = lRow + 1 End With Next oCom End If oCom.GUID oCom.progID oCom.Creator oCom.Description

' Autofit the





End Sub

Was this article helpful?

0 0

Post a comment