現在のプレゼンテーションファイルの場所(パス)を取得する方法。
MsgBox ActivePresentation.Path 現在のプレゼンテーションファイルの場所(パス)を取得する方法。
MsgBox ActivePresentation.Path Sub Macro1()
With ActivePresentation.Slides(1).Shapes("Text Box 1").TextFrame.TextRange
Do While .BoundHeight > 20 ' テキストボックスの高さが20以上の場合は2段だと判断
.Font.Size = .Font.Size - 1
Loop
End With
End Sub
shapes("Text Box1")の部分は、ファイルによって違いますので、「マクロの記録」機能を使って調べましょう。
Sub Macro1()
With ActivePresentation.Slides(1).Shapes("Text Box 1").TextFrame.TextRange
Do While .BoundHeight > 500 ' 横幅500ポイントに収まるまで、フォントを縮小
.Font.Size = .Font.Size - 1
Loop
End With
End Sub