I have this vba code but it returns ALL of the sheet names. But I want another-one that returns the sheets that start with the letter "D" and list them in column H58 on "switchboard".
Sub WORKSHEETLIST()
Dim ws As Worksheet
Dim Counter As Integer
Counter = 0
For Each ws In ActiveWorkbook.Worksheets
Sheets("switchboard").Range("c58").Offset(Counter, 0).Value = ws.Name
Counter = Counter + 1
Next ws
End Sub
Sub WORKSHEETLIST()
Dim ws As Worksheet
Dim Counter As Integer
Counter = 0
For Each ws In ActiveWorkbook.Worksheets
Sheets("switchboard").Range("c58").Offset(Counter, 0).Value = ws.Name
Counter = Counter + 1
Next ws
End Sub