Distribute Method

         Example         Applies To

Evenly distributes the shapes in the specified range of shapes. You can specify whether you want to distribute the shapes horizontally or vertically and whether you want to distribute them over the entire page or just over the space they originally occupy.

Syntax

expression.Distribute(DistributeCmd, RelativeTo)

expression   Required. An expression that returns a ShapeRange object.

DistributeCmd   Required Long. Specifies whether shapes in the range are to be distributed horizontally or vertically. Can be either of the following MsoDistributeCmd constants: msoDistributeHorizontally or msoDistributeVertically.

RelativeTo   Required Long. True to distribute the shapes evenly over the entire horizontal or vertical space on the page. False to distribute them within the horizontal or vertical space that the range of shapes originally occupies.