Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. PowerPoint Automation Doco?

PowerPoint Automation Doco?

Scheduled Pinned Locked Moved C / C++ / MFC
c++testingtoolshelptutorial
3 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • T Offline
    T Offline
    Todd Hoop
    wrote on last edited by
    #1

    I am trying to build a PowerPoint presentation using automation in MFC and not getting real far. As usual, the code examples given by MS in MSDN on how to do this only shows the advanced topics and leaves the easy stuff as an exercise. The problem is that there is no offical documentation that I can find on doing the easy stuff like adding a text box and changing the font color. I was wondering if anyone knows of any documention and/or better examples on adding/formatting slides in a presentation. What I am trying to do is simple and shouldn't be this hard :eek: . I am adding text boxes which I figured out after many hours but I am unable to change the font color. I would like to do more once I figure out how the interface works. Thanks!

    T 1 Reply Last reply
    0
    • T Todd Hoop

      I am trying to build a PowerPoint presentation using automation in MFC and not getting real far. As usual, the code examples given by MS in MSDN on how to do this only shows the advanced topics and leaves the easy stuff as an exercise. The problem is that there is no offical documentation that I can find on doing the easy stuff like adding a text box and changing the font color. I was wondering if anyone knows of any documention and/or better examples on adding/formatting slides in a presentation. What I am trying to do is simple and shouldn't be this hard :eek: . I am adding text boxes which I figured out after many hours but I am unable to change the font color. I would like to do more once I figure out how the interface works. Thanks!

      T Offline
      T Offline
      Tomasz Sowinski
      wrote on last edited by
      #2

      Todd Hoop wrote: The problem is that there is no offical documentation that I can find on doing the easy stuff like adding a text box and changing the font color. I didn't play with automating PowerPoint - only with Excel and Word. The best way to get basic knowledge of the object model is to record some macros. You'll get the VB code in VBA Editor which you should be able to quite easily translate into C++ calls - method names will be identical. Just add textboxes and change the color. Also, press F2 in VBA and you'll get Object Browser which presents objects, methods and properties. Tomasz Sowinski -- http://www.shooltz.com

      T 1 Reply Last reply
      0
      • T Tomasz Sowinski

        Todd Hoop wrote: The problem is that there is no offical documentation that I can find on doing the easy stuff like adding a text box and changing the font color. I didn't play with automating PowerPoint - only with Excel and Word. The best way to get basic knowledge of the object model is to record some macros. You'll get the VB code in VBA Editor which you should be able to quite easily translate into C++ calls - method names will be identical. Just add textboxes and change the color. Also, press F2 in VBA and you'll get Object Browser which presents objects, methods and properties. Tomasz Sowinski -- http://www.shooltz.com

        T Offline
        T Offline
        Todd Hoop
        wrote on last edited by
        #3

        Tomasz, Thanks for the reply. I tried that path which does give an idea on how the objects come together but when implemented (changing font color in this case), I received errors stating that I am using objects that are not allowed in the current view. I believe it is from a .Select() call which is used to select the text to receive the font color change. I will check out Objects Browser to see if it offers any clues. Thanks!

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups