TextBox
Contents
[
Hide
]Shape.TextBox property
Defines attributes that specify how text is displayed in a shape.
public TextBox TextBox { get; }
Examples
Shows how to set the orientation of text inside a text box.
Document doc = new Document();
DocumentBuilder builder = new DocumentBuilder(doc);
Shape textBoxShape = builder.InsertShape(ShapeType.TextBox, 150, 100);
TextBox textBox = textBoxShape.TextBox;
// Move the document builder to inside the TextBox and add text.
builder.MoveTo(textBoxShape.LastParagraph);
builder.Writeln("Hello world!");
builder.Write("Hello again!");
// Set the "LayoutFlow" property to set an orientation for the text contents of this text box.
textBox.LayoutFlow = layoutFlow;
doc.Save(ArtifactsDir + "Shape.TextBoxLayoutFlow.docx");
See Also
- class TextBox
- class Shape
- namespace Aspose.Words.Drawing
- assembly Aspose.Words