Bug: Shape object's Type property under OfficeXP

  • Thread starter Thread starter Rick Hodder
  • Start date Start date
R

Rick Hodder

Hi,

I have code that parses powerpoint slides into a
particular HTML format. I need to retrieve the pictures
out of the presentation. The only way that I could do
this was to use automation to save the powerpoint as web
page, and then parse pres.xml to find the order and names
of slides, and then parse the slide HTM files looking for
corresponding <v:imagedata tags.

While doing this, I would walk the shape collection of
the slides, looking for a shape type of 7 (Picture) or 13
(OLE Embedded Picture) and then lookup the slide in
pres.xml and parse the slide HTM to find information on
the picture (file name from o:title, etc). I would also
calculate the equivalent height and width for the picture
from the shape's Height and Width properties.

This worked fine under Office2000, but under OfficeXP
Professional, (my client experiences the same problem in
OfficeXP) the Type property of Shape of pictures is 14
(Placeholder). So, now I cant find the pictures, and esp.
the height and width.

1. Is there another way to find out whether something is
a picture?
2. Is there a fix for this problem

I have tested this under OfficeXP Professional without
SPs, under SP1, and under SP2.

Thanks,
Rick
 
This worked fine under Office2000, but under OfficeXP
Professional, (my client experiences the same problem in
OfficeXP) the Type property of Shape of pictures is 14
(Placeholder). So, now I cant find the pictures, and esp.
the height and width.

If you turn off the Automatic Layout misfeature in PowerPoint XP, it will
stop converting pictures and other content into .Type 14 / Placeholder
objects. Tools, Autocorrect, and remove the check next to Automatic Layout
for inserted objects.
1. Is there another way to find out whether something is
a picture?

Manually or programmatically duplicate the placeholder. It'll generally
revert to original .Type so you can do what you need to do on the dupe then
delete it when done.
2. Is there a fix for this problem

See above, to keep it fom happening further.
If we find out who designed and implemented this, you can have them.
After I'm done. ;-)

No real fix that I know of.
 
Rick,
I just found this the other day too. Steve Rindsberg has the answer. I
already forgot it (g). Hey Stevie, wake up!

Brian Reilly, PowerPoint MVP
 
I just found this the other day too. Steve Rindsberg has the answer. I
already forgot it (g). Hey Stevie, wake up!

Already downthread someplace. Happy Birthday!
 
Hi Again Brian,

Do you know if there are plans to fix this in the next
service pack (if there even is one - i hear that Office
2003 is in beta now)?

Rick
 
I haven't discussed this particular issue with MS and I'd say it is
"by design" and will not change,

I've complained about it; I doubt it'll change any time soon, if at all.
especially since the workaround is
such a minor issue. In fact, most of us wouldn't run into it since we
all have that placeholder thingie turned off.

Correction: Most of us who already have teethmarks on our backsides have it
turned off. It's on by default and most people, I'm convinced, never turn
it off because they have no idea it's there or why it causes the problems it
does.
 
Back
Top