Excel) (TextFrame 物件
代表 Shape 物件中的文字圖文框。 包含文字圖文框中的文字,以及控制文字圖文框對齊和錨定的屬性和方法。
註解
使用Shape物件的TextFrame屬性可傳回TextFrame物件。
範例
下列範例會在 myDocument 中新增矩形,並且在矩形中新增文字,然後設定文字圖文框的邊界。
Set myDocument = Worksheets(1)
With myDocument.Shapes.AddShape(msoShapeRectangle, _
0, 0, 250, 140).TextFrame
.Characters.Text = "Here is some test text"
.MarginBottom = 10
.MarginLeft = 10
.MarginRight = 10
.MarginTop = 10
End With
方法
屬性
- Application
- AutoMargins
- AutoSize
- Creator
- HorizontalAlignment
- HorizontalOverflow
- MarginBottom
- MarginLeft
- MarginRight
- MarginTop
- Orientation
- Parent
- ReadingOrder
- VerticalAlignment
- VerticalOverflow
另請參閱
支援和意見反應
有關於 Office VBA 或這份文件的問題或意見反應嗎? 如需取得支援服務並提供意見反應的相關指導,請參閱 Office VBA 支援與意見反應。
意見反應
https://aka.ms/ContentUserFeedback。
即將登場:在 2024 年,我們將逐步淘汰 GitHub 問題作為內容的意見反應機制,並將它取代為新的意見反應系統。 如需詳細資訊,請參閱:提交並檢視相關的意見反應