Skip to main content
Row

ShapeCollection.GetShapesByName(String) Method

Gets a drawing object(s) by name.

Namespace: DevExpress.Spreadsheet

Assembly: DevExpress.Spreadsheet.v24.1.Core.dll

NuGet Package: DevExpress.Spreadsheet.Core

Declaration

IList<Shape> GetShapesByName(
    string shapeName
)

Parameters

Name Type Description
shapeName String

A string that is the name of a drawing object.

Returns

Type Description
IList<Shape>

A collection of drawing objects with the same name.

Remarks

A drawing object name is specified by the Shape.Name property. A worksheet may contain more than one drawing object with the same name. In this situation, the IList<T><Shape,> collection returned by the GetShapesByName method contains several items.

If a drawing object with the specified name is not found, the method returns an empty list.

The following code snippet (auto-collected from DevExpress Examples) contains a reference to the GetShapesByName(String) 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.

See Also