Consulting

Results 1 to 6 of 6

Thread: Text fit properly within different size shapes to its maximum size using vba code.

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1

    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.

    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
    Attached Files Attached Files

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •