View Single Post
 
Old 06-03-2017, 08:56 PM
Guessed's Avatar
Guessed Guessed is offline Windows 10 Office 2013
Expert
 
Join Date: Mar 2010
Location: Canberra/Melbourne Australia
Posts: 4,166
Guessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant future
Default

This should get you started
Code:
Sub EmptyShapes()
  Dim aShp As Shape, aShp2 As Shape
  For Each aShp In ActiveDocument.Shapes
    If aShp.TextFrame.HasText Then
      aShp.Fill.Visible = False
    ElseIf aShp.Type = msoGroup Then
      For Each aShp2 In aShp.GroupItems
        If aShp2.TextFrame.HasText Then
          aShp2.Fill.Visible = False
        End If
      Next aShp2
    End If
  Next aShp
End Sub
This only does one level of grouping. You may need to rewrite it to use a recursive function in case there are nested groups (ie groups of groups).
__________________
Andrew Lockton
Chrysalis Design, Melbourne Australia
Reply With Quote