Hi,
we have created images and shapes in a word document. We read the shapes by its alternative text. We make some shapes as Textbox. All are working fine except first shape. If the first shape is textbox then the Aspose dll consider it as Rectangle. The below is the code which i am using.
var doc = new Document(fileName);
var collector = new LayoutCollector(doc);
var enumerator = new LayoutEnumerator(doc);foreach (Aspose.Words.Drawing.Shape img in doc.GetChildNodes(NodeType.Shape, true)) { enumerator.Current = collector.GetEntity(img); if (string.IsNullOrEmpty(img.AlternativeText) || (img.ShapeType != Aspose.Words.Drawing.ShapeType.Image && img.ShapeType != Aspose.Words.Drawing.ShapeType.Rectangle)) continue; }
Scenario to test Text box.zip (35.6 KB)