Aspose::Cells::Drawing::ShapeCollection::DeleteShape method

ShapeCollection::DeleteShape method

Delete a shape. If the shape is in the group or is a comment shape, it will not be deleted.

void Aspose::Cells::Drawing::ShapeCollection::DeleteShape(const Shape &shape)
ParameterTypeDescription
shapeconst Shape&

Examples

    //add first shape
Shape firstShape = shapes.AddRectangle(2, 0, 2, 0, 50, 50);
//add second shape
Shape secondShape = shapes.AddRectangle(6, 0, 2, 0, 30, 30);
//del
shapes.DeleteShape(firstShape);

See Also