Search code examples
vbafontspowerpoint

Removing character spacing


I'm trying to remove the character spacing (i.e. normal, not condensed or expanded) from all text in PowerPoint slides.

I know the following code but could not find the proper object of textFrame.

With ActivePresentation 
For Each oSl In .Slides 
For Each oSh In oSl.Shapes 
With oSh If .HasTextFrame 
Then If .TextFrame.HasText 
Then .TextFrame.TextRange.?? = normal

Solution

  • Instead of .TextFrame, use .TextFrame2, like so:

    .TextFrame2.TextRange.Font.Spacing = 0