none
Embedding Bitmap Image in PowerPoint RRS feed

  • Question

  • Knowing that Shapes.AddPicture takes already existing file as one of its parameters, I was wondering if there is a way to add "in-memory" bitmap object as a picture into PowerPoint slide? For example, my desktop app wants to capture a series of screen shots and add them to PowerPoint slides accordingly. If I have to save each screen grab to an actual file in system and then reference that, it seems inefficient/impractical.

    Thanks in advance for your inputs,
    Wednesday, January 12, 2011 5:00 PM

Answers

  • Hi archenil

    If the image is on the Clipboard you can insert it into PowerPoint using a Paste method. I'm not conversant enough with the PowerPoint object model to give you the exact syntax, I just know it should be possible. In this case, you would NOT need to save the graphic to disk - it would be embedded straight into the presentation.

    How to manipulate it once it's been pasted is another question, entirely :-)

    It might be best to ask about the "how to" in the specialized powerPoint forums on Answers. That's where the application object model specialists hang out.

    http://social.answers.microsoft.com/Forums/en-US/group/Office


    Cindy Meister, VSTO/Word MVP
    Wednesday, January 12, 2011 8:15 PM
    Moderator

All replies

  • Hi archenil

    The only other method is to Paste from the Clipboard.

    Most screen-shot software I'm familiar with does put the data on the Clipboard...


    Cindy Meister, VSTO/Word MVP
    Wednesday, January 12, 2011 5:10 PM
    Moderator
  • Thanks, Cindy

    Even if you save screen shot image to clipboard, you still need to save it locally so Shapes.AddPicture can reference it, right?

    Wednesday, January 12, 2011 5:44 PM
  • Hi archenil

    If the image is on the Clipboard you can insert it into PowerPoint using a Paste method. I'm not conversant enough with the PowerPoint object model to give you the exact syntax, I just know it should be possible. In this case, you would NOT need to save the graphic to disk - it would be embedded straight into the presentation.

    How to manipulate it once it's been pasted is another question, entirely :-)

    It might be best to ask about the "how to" in the specialized powerPoint forums on Answers. That's where the application object model specialists hang out.

    http://social.answers.microsoft.com/Forums/en-US/group/Office


    Cindy Meister, VSTO/Word MVP
    Wednesday, January 12, 2011 8:15 PM
    Moderator
  • That's helpful. Thanks so much, Cindy.
    Wednesday, January 12, 2011 9:29 PM