3
3
Sub cmdList()
Dim objShell As Object
Dim objFolder As Object
Dim sPath As String
Dim fOut As Variant
Dim r As Integer
Dim listRng As Range
Dim cell As Range
Dim i As Integer
Dim j As Integer
For i = 1 To listRng.Count
For j = i + 1 To listRng.Count
If InStr(listRng.Cells(j), listRng.Cells(i)) Then
With listRng.Cells(j)
.Rows.Group
.IndentLevel = .Rows.OutlineLevel - 1
End With
Else
Exit For
End If
Next j
Next i
Application.ScreenUpdating = True
End Sub