Returns the number of shapes in the collection.
[Visual Basic] Property ReadOnly Count As Integer [C#] int Count { get; } [C++] __property int get_Count(); [JScript] function get Count() : int
Integer. The number of shapes in the IShapes collection.
This example uses the Count property to set the value of A1 cell on the first sheet.
[C#]
IWorksheet sheet = book.Worksheets[1];
sheet.Range["A1"].Value = sheet.Shapes.Count;
[Visual Basic]
Dim sheet As IWorksheet = book.Worksheets(1)
sheet.Range("A1").Value = sheet.Shapes.Count
[C++]
IWorksheet* sheet = book->Worksheets->Item[1];
sheet->Range->Item[S"A1"]->Value = sheet->Shapes->Count;
IShapes Interface | NativeExcel Namespace