Visio Guy

Visio Discussions => Programming & Code => Topic started by: hophead on July 28, 2009, 01:33:51 AM

Title: Foreign Image Info Questions
Post by: hophead on July 28, 2009, 01:33:51 AM
I have some questions about the foreign image info section of the shapesheet.

First, How can I show it?

I have some downloaded shapes and somehow I managed to show it once and it intrigued me.

I would like to write a macro that can toggle the foreign image graphic on and off. There may be a better way but from the one shape I can see that section on I think I can hide the image by making the height or width 0 (height*0 or Width *0 vs height*1 or width*1)

Is there a better way to "blank" the graphic?

when we release a drawing it gets scanned to share online with other disaplines in the company and the customer. To provide a clean, legible rack map drawing we want to be able to turn the grpahinc off and show a box with text in it.

Thanks
Title: Re: Foreign Image Info Questions
Post by: Paul Herber on July 28, 2009, 05:48:51 AM
The Foreign Image section of the shapesheet is only shown if the shape is an image. Use the menu Insert -> Picture -> From File.
The image can be hidden using the cells ImgWidth or ImgHeight or set the shape transparency to 100%.

Title: Re: Foreign Image Info Questions
Post by: Visio Guy on July 28, 2009, 10:18:12 AM
Good tips, Paul!

Along the same lines of thought: you can "crop" the image inside of the SheetSheet so that the image is essentially slid out of the visible rectangle:

Foreign Image Info.ImgWidth = Width*-1  (instead of Width*1)

Read my treatise on The Hidden World of Visio Shapes (http://www.visguy.com/2006/09/05/the-hidden-world-of-visio-shapes/) for more info about hiding shapes and parts of shapes.
Title: Re: Foreign Image Info Questions
Post by: hophead on July 28, 2009, 10:39:37 PM

It appears that the image I need to "hide" is grouped such that it doesn't show on the shapesheet for the shape. If I ungroup the shape, I loose all the connection pts, control pts, custom shapes data, etc. But I can then open the a shapesheet that has the foreign image info available to change.

Is there a way to get to the shapesheet the image is on without ungrouping the shape and losing all the associated info?

Thanks
Title: Re: Foreign Image Info Questions
Post by: Paul Herber on July 29, 2009, 12:09:36 PM
Don't ungroup the shape.
To look at the sub-shapes in the group use menu
View -> Document Explorer Window
Once you've found the shape then drill down to the sub-shapes and use the right-click menu and select Show Shapesheet

Title: Re: Foreign Image Info Questions
Post by: Visio Guy on July 29, 2009, 12:45:59 PM
You can also dive into the group by opening the group window. Select the group, then choose Edit > Open Group. "Group" might say a shape name instead, like Open Monitor or Open Process, depending on the name of your shape.

You might want to check out this article: What's My Shape's ID? (http://www.visguy.com/2009/07/15/whats-my-shapes-id/)