= Attach on powerpoint Slide =
tested on Powerpoint2003@Windows XP
Find and click "Control Toolbox" and select "Shockwave Flash Object" from the list. Then, draw the control in your slide.
Right-click at the control and select "Properties".
Specify your movie location on the "Movie" property and modify "WMode" property to "Direct" or "gpu".
(default value "Window" is not valid for Stage3D swfs.)
See also [http://support.microsoft.com/kb/291875/ Microsoft Support page] for detailed instruction.
Please use newer versions (0.20 or later) for this purpose, since older versions (0.16 or before) need
an additional setting to display on powerpoint and have terrible bugs.
Note that newer version (0.20 or later) are still buggy and not so stable. It sometimes freezes.
== VBA script ==
* class module
{{{ code vba
Public WithEvents appevent As Application
Private Sub appevent_SlideShowNextSlide(ByVal Wn As SlideShowWindow)
Dim sld As Slide
Set sld = Wn.View.Slide
Dim s As shape
For Each s In sld.Shapes
If s.Name Like "ShockwaveFlash*" Then
Dim swf As ShockwaveFlash
Set swf = s.OLEFormat.Object
Dim fn As String
fn = swf.Movie
With swf
.Movie = "dummy"
.Movie = fn
.WMode = "Direct"
.FrameNum = -1
.Playing = True
End With
End If
Next
End Sub
}}}
This function is called when a slide is shown. All the shock wave flash objects in the slide are forced to reload.
This is done by setting Movie property to dummy file name ("dummy") and then put the name back to the original one.
This ridiculous operation can force reload the movie. I do not know any sophisiticated ways. Only rewind the movie
usually does not work correctly.
* module
{{{ code vba
Dim myobject As New Class1
Sub startEvents()
Set myobject.appevent = Application
End Sub
Sub stopEvents()
Set myobject.appevent = Nothing
End Sub
}}}
To use these functions, launch VBA editor in the powerpoint first. Then create new class module (its name may be Class1) and
write the SlideShowNextSlide function above. Next, create new module and write the startEvents and stopEvents functions.
Quit VBA editor and exec startEvents() from macro. Use at your own risk.
This code is tested on powerpoint2003@Windows XP