Since you haven't posted a sample file we can only guess at how your racks are structured. You can use a macro to count the shapes and subshapes on each page. This code below returns the output to the immediate window. You could modify it to process all pages or just the selected shapes depending on what you actually need it to do.
Code:
Sub CountEmUp()
Dim aShp As Shape, aSubShape As Shape
For Each aShp In ActivePage.Shapes
Debug.Print aShp.Text, aShp.Master, aShp.Shapes.Count
If aShp.Shapes.Count > 0 Then
For Each aSubShape In aShp.Shapes
Debug.Print "", aSubShape.Text, aSubShape.Master, aSubShape.Shapes.Count
Next aSubShape
End If
Next aShp
End Sub