共用方式為


TextFrame.MarginTop 屬性 (PowerPoint)

返回或設定文字框頂端與包含文字形狀內切矩形頂端之間的 ) (點。 讀取/寫入。

語法

表情MarginTop

一個代表 TextFrame 物件的變數。

傳回值

單一

範例

本範例會在 myDocument 中新增矩形,並在該矩形中新增文字,然後設定文字圖文框的邊界。

Set myDocument = ActivePresentation.Slides(1)

With myDocument.Shapes.AddShape(msoShapeRectangle, _
        0, 0, 250, 140).TextFrame
    .TextRange.Text = "Here is some test text"
    .MarginBottom = 0
    .MarginLeft = 10
    .MarginRight = 0
    .MarginTop = 20
End With

另請參閱

TextFrame 物件

支援和意見反應

有關於 Office VBA 或這份文件的問題或意見反應嗎? 如需取得支援服務並提供意見反應的相關指導,請參閱 Office VBA 支援與意見反應