[]
Moves the specified shape in front of or behind other shapes in the collection.
Use ZOrderPosition to determine the current z-order position of a shape. If the z-order of a shape is changed, the index of the shape in the worksheet's shapes collection also changes.
void ZOrder(ZOrderType zOrderType)
Sub ZOrder(zOrderType As ZOrderType)
| Type | Name | Description |
|---|---|---|
| ZOrderType | zOrderType | The z-order command that specifies where to move the shape relative to the other shapes. This value is required. |
IShape rectangle = worksheet.Shapes.AddShape(AutoShapeType.Rectangle, 20, 20, 120, 60);
IShape oval = worksheet.Shapes.AddShape(AutoShapeType.Oval, 40, 30, 120, 60);
rectangle.ZOrder(ZOrderType.BringForward);