officefileapi-devexpress-dot-spreadsheet-dot-shape-ed73e76c.md
Deletes a drawing object.
Namespace : DevExpress.Spreadsheet
Assembly : DevExpress.Spreadsheet.v25.2.Core.dll
NuGet Package : DevExpress.Spreadsheet.Core
void Delete()
Sub Delete
The Delete method removes the current Shape from the collection of Worksheet.Shapes in the current worksheet.
The following code snippets (auto-collected from DevExpress Examples) contain references to the Delete() method.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.
Picture pic = worksheet.Pictures.GetPicturesByName("Picture 4")[0];
pic.Delete();
}
Shape picShape = worksheet.Shapes.GetShapesByName("Picture 4")[0];
picShape.Delete();
}
// Remove the last inserted picture.
picShape.Delete();
}
Dim pic As Picture = worksheet.Pictures.GetPicturesByName("Picture 4")(0)
pic.Delete()
Finally
Dim picShape As Shape = worksheet.Shapes.GetShapesByName("Picture 4")(0)
picShape.Delete()
Finally
' Remove the last inserted picture.
picShape.Delete()
Finally
See Also