Visio Guy

Visio Discussions => General Visio => Topic started by: wxaggie11 on March 15, 2011, 07:09:56 PM

Title: How to Select Shape on NEXT Page
Post by: wxaggie11 on March 15, 2011, 07:09:56 PM
Howdy,

I would like to be able to select a shape I create through VBA on the page after the one I'm looking at. Right now, I can drop the shape easily on the next page, however it is in front of others, when I need it to be behind. How can I select this shape and then command it to be sent to the back?
Title: Re: How to Select Shape on NEXT Page
Post by: Paul Herber on March 15, 2011, 07:30:29 PM
You don't need to have the shape selected to do this, when you dropped the shape on the page the drop method returns a shape object (shpobj), just use shpobj.SendToBack
(I think that's the correct syntax, I'm away from Visio at the moment)
Title: Re: How to Select Shape on NEXT Page
Post by: wxaggie11 on March 15, 2011, 07:37:24 PM
Set FieldLabelEntry = pagObj.Drop(FieldLabelMaster, StartX(1), StartY(1))
        FieldLabelEntry.SendToBack


I entered that, and that did not work. Do I need to use something other than the variable I set it to?
Title: Re: How to Select Shape on NEXT Page
Post by: wxaggie11 on March 15, 2011, 07:41:25 PM
HAHAHAH my shapes are hollow. That explains it. It works with a solid shape :) Thanks