View Single Post
 
Old 03-14-2022, 11:40 PM
Guessed's Avatar
Guessed Guessed is offline Windows 10 Office 2016
Expert
 
Join Date: Mar 2010
Location: Canberra/Melbourne Australia
Posts: 4,176
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

The most logical thing is not to select it in the first place
Code:
Sub TestMacro()
  Dim shp As Shape, aRng As Range
  For Each shp In ActiveDocument.Sections(1).Headers(wdHeaderFooterPrimary).Shapes
    If shp.Type = msoTextBox Then
        Set aRng = shp.TextFrame.TextRange
        aRng.MoveStart Unit:=wdCharacter, Count:=1
        aRng.Font.Subscript = True
    End If
  Next
End Sub
__________________
Andrew Lockton
Chrysalis Design, Melbourne Australia
Reply With Quote