Publisher () 的 TextFrame.BreakForwardLink 方法

中斷指定文字圖文框的前導連結 (如果此連結存在話)。

語法

運算式BreakForwardLink

表達 代表 TextFrame 物件的變數。

註解

將這個方法套用至含有連結文字圖文框之圖形鏈結中間的圖形會中斷鏈結,留下兩組連結的圖形。 不過,所有文字都會保留在第一個連結圖形系列中。

範例

本範例建立一個新出版物,在其中新增一個由三個連結文字方塊組成的鍊,然後中斷第二個文字方塊後的連結。

Sub BreakTextLink() 
 Dim shpTextbox1 As Shape 
 Dim shpTextbox2 As Shape 
 Dim shpTextbox3 As Shape 
 
 Set shpTextbox1 = ActiveDocument.Pages(1).Shapes.AddTextbox _ 
 (Orientation:=msoTextOrientationHorizontal, _ 
 Left:=72, Top:=36, Width:=72, Height:=36) 
 shpTextbox1.TextFrame.TextRange = "This is some text. " _ 
 & "This is some more text. This is even more text. " _ 
 & "And this is some more text and even more text." 
 
 Set shpTextbox2 = ActiveDocument.Pages(1).Shapes.AddTextbox _ 
 (Orientation:=msoTextOrientationHorizontal, _ 
 Left:=72, Top:=108, Width:=72, Height:=36) 
 
 Set shpTextbox3 = ActiveDocument.Pages(1).Shapes.AddTextbox _ 
 (Orientation:=msoTextOrientationHorizontal, _ 
 Left:=72, Top:=180, Width:=72, Height:=36) 
 
 shpTextbox1.TextFrame.NextLinkedTextFrame = shpTextbox2.TextFrame 
 shpTextbox2.TextFrame.NextLinkedTextFrame = shpTextbox3.TextFrame 
 MsgBox "Textboxes 1, 2, and 3 are linked." 
 shpTextbox2.TextFrame.BreakForwardLink 
End Sub

支援和意見反應

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