Identifying Pictures and Drawing Objects

R

Ridge Kennedy

I've done some work with a template that shows and hides graphic images --
allowing a user to fax a document (show image of logo) or print the document
on letterhead (hiding image of logo). I found that the picures came in as
"Picture 11" and "Picture 22" and so on. I was able to identify them by
using the recorder and selecting them and then looking at the code. But I
was wondering if there is any, more efficient way, to identify image and
drawing objects?

Ridge (in New Joisey)
 
C

Cindy M -WordMVP-

Hi Ridge,
I've done some work with a template that shows and hides graphic images --
allowing a user to fax a document (show image of logo) or print the document
on letterhead (hiding image of logo). I found that the picures came in as
"Picture 11" and "Picture 22" and so on. I was able to identify them by
using the recorder and selecting them and then looking at the code. But I
was wondering if there is any, more efficient way, to identify image and
drawing objects?
Using the names Word generates is very unreliable; it can change the names at
the drop of a hat. Better to assign your own names. Once a graphical object
(Shape) has a custom name, then that's the best way to address them.

For InlineShapes, bookmarks are good.

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 8 2004)
http://www.word.mvps.org

This reply is posted in the Newsgroup; please post any follow question or
reply in the newsgroup and not by e-mail :)
 
R

Ridge Kennedy

Dear Cindy,

thnak you for the follow up

You said:
Using the names Word generates is very unreliable; it can change the names at
the drop of a hat.

Actually change the name after it has been saved?? Aargh.
Better to assign your own names. Once a graphical object
(Shape) has a custom name, then that's the best way to address them.

OK, I've been looking high and low for a way to do that. When I select the
object, I can't find any reference to properties or anything like that. Can
you point me in the right direction?
For InlineShapes, bookmarks are good.

Umm -- like insert a bookmark right next to the shape?

I know I'm missiong something simple here.

Thnaks,

Ridge
 
C

Cindy M -WordMVP-

Hi Ridge,
OK, I've been looking high and low for a way to do that. When I select the
object, I can't find any reference to properties or anything like that. Can
you point me in the right direction?
Assuming you have the Shape actually selected in the UI:
Selection.ShapeRange(1).Name = "My name"

There is no interface in the UI for applying or reading names of objects in
the Drawing layer (not in-line with the text).
Umm -- like insert a bookmark right next to the shape?
Select the InlineShape, then InsertBookmark, if we're talking UI. You can then
address it with something like

Set ils = ActiveDocument.Bookmarks("Name").Range.InlineShapes(1)

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 8 2004)
http://www.word.mvps.org

This reply is posted in the Newsgroup; please post any follow question or
reply in the newsgroup and not by e-mail :)
 
R

Ridge Kennedy

Brilliant, Cindy!

Thank you.

R.


Cindy M -WordMVP- said:
Hi Ridge,

Assuming you have the Shape actually selected in the UI:
Selection.ShapeRange(1).Name = "My name"

There is no interface in the UI for applying or reading names of objects in
the Drawing layer (not in-line with the text).

Select the InlineShape, then InsertBookmark, if we're talking UI. You can then
address it with something like

Set ils = ActiveDocument.Bookmarks("Name").Range.InlineShapes(1)

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 8 2004)


This reply is posted in the Newsgroup; please post any follow question or
reply in the newsgroup and not by e-mail :)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top