Deleting InlineShapes

S

Senad Isanovic

I'm trying to delete logo from the header in the doc. The logotype is there,
but when I'm running this code rs.InlineShapes.Count is 0. What's wring?
thanks!

Dim rs As Range
Set rs =
ActiveDocument.Sections(1).Headers(wdHeaderFooterPrimary).Range
If rs.InlineShapes.Count > 0 Then
rs.InlineShapes(1).Delete
End If
 
C

Chuck Henrich

It might be a Shape instead of an InlineShape - try testing for the Shapes
count.
 
Top