PPT 2007 Bug?

B

Burnsie

In 2003 I could do the following:

shape.textframe.textrange.paragraphs(i).insertafter.paste

Now I get a runtime error:
The specified parameter has an invalid value.

Even running the following snippet from the help files produces the same
error.

Application.ActivePresentation.Slides(1).Shapes(1).TextFrame _
.TextRange.InsertAfter.Paste

Yet, if I replace the paste with some text string, then all is well.
However, it is important that I be able to paste because I need to maintain
the formating from the section that I moving to this section of the slide.

Thanks,

Burnsie
 
S

Shyam Pillai

Yes, this is a bug with the InsertAfter in PPT 2007 reported by, Word MVP,
Jonathan West. Use the following code instead to get the same effect.

Application.ActivePresentation.Slides(1).Shapes(1).TextFrame _
.TextRange.InsertAfter(" ").Paste

Regards,
Shyam Pillai

Image Importer Wizard
http://skp.mvps.org/iiw.htm
 

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