OK, OK, I can see now.
I just had lost track of the questions and answers.
Got this all worked out now the way I need it:
Sub ShowHelpContextIDsAndTags()
Dim oVBProj As VBProject
Dim oVBComp As VBComponent
Dim ctl As MSForms.Control
Dim strFormName As String
Dim strFormTag As String
Dim lFormHelpID As Long
Dim oProp As Object
Dim i As Long
Application.ScreenUpdating = False
Cells.Clear
Cells(1) = "Control Type"
Cells(2) = "Form Name"
Cells(3) = "Form Help ID"
Cells(4) = "Form Tag"
Cells(5) = "Control Name"
Cells(6) = "Control Tag"
Cells(7) = "Control Help ID"
Range(Cells(1), Cells(7)).Font.Bold = True
MediumBottomBorder Range(Cells(1), Cells(7))
i = 1
Set oVBProj = ThisWorkbook.VBProject
On Error Resume Next
For Each oVBComp In oVBProj.VBComponents
If oVBComp.Type = 3 Then
strFormName = ""
strFormTag = ""
lFormHelpID = 0
For Each oProp In oVBComp.Properties
If oProp.Name = "Name" Then
strFormName = oProp.Value
Exit For
End If
Next
For Each oProp In oVBComp.Properties
If oProp.Name = "HelpContextID" Then
lFormHelpID = oProp.Value
Exit For
End If
Next
For Each oProp In oVBComp.Properties
If oProp.Name = "Tag" Then
strFormTag = oProp.Value
Exit For
End If
Next
For Each ctl In oVBComp.Designer.Controls
If TypeName(ctl) <> "Image" And _
TypeName(ctl) <> "ImageList" And _
TypeName(ctl) <> "CommonDialog" Then
If ctl.Tag <> "" Then
i = i + 1
Cells(i, 1) = TypeName(ctl)
Cells(i, 2) = strFormName
Cells(i, 3) = lFormHelpID
Cells(i, 4) = strFormTag
Cells(i, 5) = ctl.Name
Cells(i, 6) = ctl.Tag
Cells(i, 7) = ctl.HelpContextID
Else
If ctl.HelpContextID > 0 Then
i = i + 1
Cells(i, 1) = TypeName(ctl)
Cells(i, 2) = strFormName
Cells(i, 3) = lFormHelpID
Cells(i, 4) = strFormTag
Cells(i, 5) = ctl.Name
Cells(i, 6) = ctl.Tag
Cells(i, 7) = ctl.HelpContextID
End If
End If
End If
Next
End If
Next
With Range(Cells(1), Cells(i, 7))
.Columns.AutoFit
.HorizontalAlignment = xlLeft
.Name = "HelpContextIDsAndTags"
End With
Application.ScreenUpdating = True
End Sub
Sub MediumBottomBorder(rng As Range)
With rng
With .Borders(xlEdgeBottom)
.LineStyle = xlContinuous
.Weight = xlMedium
.ColorIndex = xlAutomatic
End With
End With
End Sub
RBS