VBA to set logo in the header as Decorative
I have macro code to set Alt Text for small images in a document to Decorative.
Sub alttext()
Dim shp As InlineShape
Dim doc As Document
Set doc = ActiveDocument
For Each shp In doc.InlineShapes
If shp.Width >= InchesToPoints(2) And shp.Height >= InchesToPoints(1) Then
shp.AlternativeText = “Figure. Caption.”
Else
shp.Decorative = True
End If
Next shp
End Sub
Works great. I need to set Alt Text for my logo in the Header to Decorative.
I cannot seem to figure this one out.
Please help.
I have macro code to set Alt Text for small images in a document to Decorative.Sub alttext()
Dim shp As InlineShape
Dim doc As Document
Set doc = ActiveDocument
For Each shp In doc.InlineShapes
If shp.Width >= InchesToPoints(2) And shp.Height >= InchesToPoints(1) Then
shp.AlternativeText = “Figure. Caption.”
Else
shp.Decorative = True
End If
Next shp
End SubWorks great. I need to set Alt Text for my logo in the Header to Decorative.I cannot seem to figure this one out.Please help. Read More