1 Attachment(s)
Text fit properly within different size shapes to its maximum size using vba code.
Sir, need some help to configure emoji(as a text) to properly fit(cover almost shape size but not overflow) into different size shapes.
I tried to give some fix font size like 700 & then apply "msoAutoSizeTextToFitShape" but it overflow the shape boundary.
For better understanding I uploaded sample file where I showed the final outcome.
Any solution will be highly appreciated.
Code:
Sub proper_fit()
Dim shpImage As Shape
Set shpImage = ActivePresentation.Slides(1).Shapes("shape1")
With shpImage
.TextFrame.TextRange.Font.Size = 700
.TextFrame2.AutoSize = msoAutoSizeTextToFitShape
End With
End Sub