ShapeBaseTitle Property
Gets or sets the title (caption) of the current shape object.

Namespace: Aspose.Words.Drawing
Assembly: Aspose.Words (in Aspose.Words.dll) Version: 19.12
Syntax
public string Title { get; set; }

Property Value

Type: String
Remarks

Default is empty string.

Cannot be null, but can be an empty string.

Examples
Shows how to get or set title of shape object.
Document doc = new Document();
DocumentBuilder builder = new DocumentBuilder(doc);

// Create test shape.
Shape shape = new Shape(doc, ShapeType.Cube);
shape.Width = 431.5;
shape.Height = 346.35;
shape.Title = "Alt Text Title";

builder.InsertNode(shape);

MemoryStream dstStream = new MemoryStream();
doc.Save(dstStream, SaveFormat.Docx);

shape = (Shape) doc.GetChild(NodeType.Shape, 0, true);
Console.WriteLine("Shape text: " + shape.Title);
See Also