Object Model Reference : Classes : T : TextFrame : Properties : TextFrame.Multicolumn |
Property Multicolumn As Boolean
Member of TextFrame
The Multicolumn property returns True if a paragraph-text frame has more than one column.
The Multicolumn property returns a read-only value.
The following VBA example links frames of paragraph text. The text in the first frame is fitted to a path and is divided into three columns, and then the number of columns in each multicolumned frame is displayed.
Sub Test() |
Dim d As Document |
Dim s As Shape |
Dim s1 As Shape |
Dim s2 As Shape |
Dim t As Text |
Dim f As TextFrame |
Set d = CreateDocument |
Set s = d.ActiveLayer.CreateParagraphText(2, 2, 5, 5, String$(750, "Z")) |
Set s1 = d.ActiveLayer.CreateParagraphText(5, 5, 8, 8) |
Set s2 = d.ActiveLayer.CreateEllipse(1, 1, 3, 3) |
Set t = s.Text |
' Fit the text to path. |
s1.Text.FitToPath s2 |
' Link the frames together. |
t.Frame.LinkTo s1 |
' Get the first frame. |
Set f = t.Frames(1) |
' Set the columns |
f.SetColumns 3, False, Array(1, 0.3, 2, 0.3, 3) |
For Each f In t.Frames |
If f.Multicolumn Then |
MsgBox "There are " & f.ColumnCount & " columns in frame " & f.Index |
End If |
Next f |
End Sub |
Copyright 2013 Corel Corporation. All rights reserved.