
This method inserts a new text frame anchored to a paragraph. The text flows around the text frame.
Introduced: 12.0.
TXTextControl.TextFrameInsert TextPos, Alignment, PosX, PosY, Width, Height, TextFlow, DistanceL, DistanceT, DistanceR, DistanceB
| Parameter | Description | ||||||||||||||||
| TextPos | Specifies a text position in the paragraph where to insert the text frame. If TextPos is -1, the text frame is anchored to the paragraph at the current input position. | ||||||||||||||||
| Alignment | Specifies the text frame's horizontal alignment. It can be one of the following values:
| ||||||||||||||||
| PosX | Specifies the text frame's horizontal position in twips relative to the left border of the paragraph. This value is used if the Alignment parameter has been set to 0. | ||||||||||||||||
| PosY | Specifies the text frame's vertical position in twips relative to the top border of the paragraph. | ||||||||||||||||
| Width | Specifies the width of the text frame in twips. | ||||||||||||||||
| Height | Specifies the height of the text frame in twips. | ||||||||||||||||
| TextFlow | Specifies how text flows around the text frame. It can be one of the following values:
| ||||||||||||||||
| DistanceL, DistanceT, DistanceR, DistanceB | Specifies distances, in twips, between the text frame and the document's text. |
The method returns the text frame's identifier, if a new text frame could be inserted. Otherwise, it returns zero. The text frame's identifier can also be obtained with the ObjectCurrent property.
| TextPos: | Long |
| Alignment: | Integer |
| PosX: | Long |
| PosY: | Long |
| Width: | Integer |
| Height: | Integer |
| TextFlow: | Integer |
| DistanceL: | Integer |
| DistanceT: | Integer |
| DistanceR: | Integer |
| DistanceB: | Integer |
| Return value: | Integer |