I want to check if addin is installed and is referenced. The below code checks for add in is installed or not. How can i check if its referenced in excel.
Sub Sample()
Dim wbAddin As Workbook
On Error Resume Next
Set wbAddin = Workbooks(AddIns("My Addin").Name)
If Err.Number <> 0 Then
On Error GoTo 0
'Set wbAddin = Workbooks.Open(AddIns("My Addin").FullName)
Debug.Print "Not Referenced"
Else
Debug.Print "Referenced"
End If
End Sub