ContainerProperties.ReorderListMember method (Visio)

Moves a shape or a set of shapes up or down in the list.


expression.ReorderListMember (ObjectToReorder, Position)

expression A variable that represents a ContainerProperties object.


Name Required/Optional Data type Description
ObjectToReorder Required [UNKNOWN] The shape or shapes to reorder in the container. Can be either Shape or Selection objects.
Position Required Long The insertion position in the list, which is one-based.

Return value



If the container is not a list, Microsoft Visio returns an Invalid Source error.

If the ObjectToReorder parameter does not contain top-level shapes on the page, if any shape in ObjectToReorder is not a member of the list, or if the list is locked, Visio returns an Invalid Parameter error.

To insert before the first item in the list, pass 1 for the Position parameter.

To insert after the final item in the list, set Position greater than or equal to the count of items.

If you pass an out-of-range value for Position, Visio uses the nearest valid position.

If you pass a non-contiguous selection of list members for ObjectToReorder, Visio makes the selection contiguous in the resulting reordered list, while maintaining relative position. For example, in a list ordered A,B,C,D, if you move B and D to position 1, the resulting list order is B,D,A,C.


The following Visual Basic for Applications (VBA) example shows how to use the ReorderListMember method to move a list member shape to the second position in the list.

vsoListShape.ContainerProperties.ReorderListMember vsoShape, 2

Support and feedback

Have questions or feedback about Office VBA or this documentation? Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.