View Single Post
Old 20-03-2012, 23:08
shelbym's Avatar
shelbym shelbym is offline
Senior Member
Join Date: Nov 2002
Location: Cheyenne, WY
Posts: 1,782
Blog Entries: 11
Send a message via ICQ to shelbym Send a message via AIM to shelbym Send a message via MSN to shelbym Send a message via Yahoo to shelbym
Default ShapeRange

Do this, by hand, not in code. Create say three rectangles and group them. Then hold down CTRL and click one of the rectangles, notice the handles change from rectangles to circles, this is because you are selecting the shape, inside the group.

Another way to look at it, same three rectangles in the group. Open the Object Manager docker. Expand the group, and you will see the three rectangles select one from the Object Manager, and you see the same circle handles, shift select and you can select all three, but again you are selection the shapes in the group, not the group. Press P to align to page, and notice they align as individual shapes.

This is exactly what your code is doing, because you are selecting the ShapeRange, aka a range of shapes, it is selecting the shapes inside the group, and not the group itself, so when you do your align, it aligns them as individual shapes.

Does that make sense? If not, let me know, and I will try to explain another way.

Reply With Quote