Q I want to make an unattended PowerPoint presentation, where:
First of all you have to enable Macros (scripting) in the PowerPoint application, in case they're disabled.
From "Tools/Macro/Security..." menu you get a "Security" dialog, where at the "Security Level" page you have to select "Medium". Make sure "High" isn't selected there (cause macros are then disabled). Also avoid selecting "Low", since it can be potentially dangerous to run scripts in PowerPoint.
Then you must close the PowerPoint application (all PowerPoint windows) and start it again.
From then on, every time you open a PowerPoint presentation that contains macros, you'll be asked whether you want to allow it to run macros or not. If you select no, you are affecting the good working of that presentation (may not play OK or with its full features), but you're safe from potential exploits, especially if you don't trust the source you got that presentation (either its author or the media via which you received that presentation)
If you use "Signed" scripts and presentations (signing can make sure a file hasn't been changed and via say a VeriSign certificate certify who authored the file), you can even use "High" security setting (more info about that in the future, please check MSDN for now)
Then you have to open the "Visual Basic Editor" from the "Tools/Macro/Visual Basic Editor" menu.
You could also right click on some empty area of the PowerPoint menus and check the "Visual Basic" item at the displayed popup menu, so that the respective toolbar is shown. You can drag that new toolbar and place it wherever it suits you (e.g. dock it onto some other toolbar). It has a button that opens the "Visual Basic Editor" (move the mouse over each toolbar button and wait a bit for a tooltip text to be shown with the title of that button's action)
At the Visual Basic Editor window, right click at the "VBAProject" tree node in the Project Explorer pane (select "View/Project Explorer" if it's not shown) and from the popup menu you select "Insert/Class Module"
Under "Class Modules", you'll then see a "Class1" item (or similar name, say "Classe1" if you have French MS-Office).
Double-click "Class1" to view its source code, which should be initially empty
Copy-paste the following code there:
Public WithEvents App As Application
Public Sub App_SlideShowNextSlide(ByVal Wn As SlideShowWindow)
Dim currentSlide As Slide
currentSlide = ActivePresentation.SlideShowWindow.View.Slide
currentSlideIndex = currentSlide.SlideIndex
Select Case currentSlideIndex
Case 1
'...
Case 2
With Slide2.QTVRControlX1
.ControllerActive = True
.ControllerVisible = True
.GoToBeginningOfMovie
.StartMovie
End With
Case 3
'maybe do Slide2.QTVRControlX1.StopMovie here
'...
End Select
End Sub
Then at the Visual Basic Editor window again, right click at the "VBAProject" tree node in the Project Explorer pane and from the popup menu you select "Insert/Module"
Under "Modules", you'll then see a "Module1" item (or similar name, say "Classe1" if you have French MS-Office).
Double-click "Class1" to view its source code, which should be initially empty
Copy-paste the following code there:
Dim x As New Class1 Sub InitializeApp() Set x.App = Application End Sub
Then, select "Debug/Compile VBAProject" if that option is available at the Visual Basic Editor menubar
Close the Visual Basic Editor
For each slide that has a QTVRControlX control to show a movie:
- select/view the slide
- right click the QTVRControlX and select "Properties"
- set property "ControllerVisible" to True (and check that "ControllerVisibleUseDefault" is set to "False")
- enter slide-show mode ("View/Slide Show" menu item or F5 key on the keyboard)
- drag the movie controller time knob all the way to the left to set the movie to time 0 (sorry for this process, will make a "Time" or similar property available soon so that one can set it to 0 from the Properties window)
- press ESC to exit slideshow mode
- right click the QTVRControlX and select "Properties" again
- set property "ControllerVisible" to "False" if you wish to have the movie controller hidden (make sure you also have "ControllerVisibleUseDefault" set to "False" so that any setting embedded in the movie file regarding movie controller visibility is ignored)
When finished, save the presentation and close all PowerPoint windows (you must reopen the presentation for the slide transition events to start working)
Open the presentation again and at the dialog that says the movie contains macros (also see [1] above), select "Enable macros" to allow the movie events to work (this is a necessery burden for security reasons: the user can set macro security to "Low", see [1] above, to never see such dialogs when opening PowerPoint presentations, but there's a high security risk in doing that [scripts are run without the user getting prompted about it to say if they trust that PowerPoint file])
Select 1st slide and enter slideshow mode. When navigating to a slide that has a movie, you'll notice it starts autoplaying.
To move to the next slide double-click at an emtpy area of the slide (single click out of the movie area, then press space char, else right click on an empty slide area and use the popup menu for navigation).
In a coming version of QTVRControlX control, there will be a MovieStopped event or similar so that you can script an automatic transition to the next slide upon termination of the movie playback
If you want your presentations to start playing when user opens the operating system (from Windows Explorer or similar), save them as "PowerPoint Show (.PPS)" instead of "PowerPoint Presentation (.PPT)" (via the "File/Save As..." menu). To edit such files you have to first open PowerPoint, then select "File/Open..." from its menu and open the ".pps" file you wish
After playing the presentation make sure to not save it again, else all your movies will keep the time at which you had saved them (this may not be true at this moment, but will be true at the future [I might add though a "SaveTime" property to be able to set it to "False" for time to not be stored when saving])