Interoperation vs Process Threading - Powerpoint Slideshow Control

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I would like to control power point slide show presentations from an
application. The presentations already exist and just need to be played. I
currently do it using a process and using the verb "Show" to run a slideshow
from my application. To my knowledge, I cannot retrieve any information about
the presentation properties for example, number of slides, slide duration
before automaticically going to the next slide.

I would like these pieces of information so that I can close a particulat
presentation precisely at the end of the show and possibly start another one.
I recently came across interoperation for office applications with C# .net
applications. I found I could get all the information i needed using a
PowerPoint object and surfing through the collections of a particular file.

Unfortunately, I couldn't find a method or means of starting a slide show
through the interoperator class. I was wondering if anyone had gone down this
path or know any technical articles I could read either about Process
management or COM interoperation with powerpoint in particular. Any help
would be awesome. Thanks
 
I haven't done this in C# but in C++ I import the PowerPoint dll and do
these commands:
stdafx.cpp
#import <msppt.olb> implementation_only
stdafx.h
#import <msppt.olb> no_implementation


PowerPoint::_ApplicationPtr pptApplication;
// specific presentation opened
PowerPoint::_PresentationPtr pptNewPresentation;
HRESULT hr = pptApplication.CreateInstance("PowerPoint.Application");
pptNewPresentation = pptApplication->Presentations->Open(
presFile.AllocSysString(),
Office::msoTrue, Office::msoFalse, Office::msoTrue );

// find the current slide being shown
CurrentSlideNbr =
pptNewPresentation->GetSlideShowWindow()->GetView()->GetSlide()->GetSlideInd
ex();
 

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

Back
Top