Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Visio Group/UnGroup

Status
Not open for further replies.

mavest

Programmer
Feb 27, 2003
54
US
I having difficulty doing a VBA Group command on 3 Visio Shapes.

What I want to do is group the 3 shapes and name the resulting group "tkgroup1".

I can successfully group the objects with the below code, but can't get a handle on the group to change its name to "tkgroup1.

Help would be appreciated - thanks!

Code Example:
Set shp1Obj = ThisDocument.Pages(apage).Shapes("Rectangle.10")
Set shp2Obj = ThisDocument.Pages(apage).Shapes("Rectangle.11")
Set shp3Obj = ThisDocument.Pages(apage).Shapes("Rectangle.12")

ActiveWindow.DeselectAll
ActiveWindow.Select shp1Obj, visSelect
ActiveWindow.Select shp2Obj, visSelect
ActiveWindow.Select shp3Obj, visSelect
ActiveWindow.Group("tkgroup1")
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top