Copy link to clipboard
Copied
I would like to export a powerpoint file to pdf and would like to keep a special powerpoint animation (i.e., an image is flying into the slide) in the pdf. How can I do this ?
Copy link to clipboard
Copied
Hioliver0541,
PowerPoint animations are not carry forwarded to the PDF. However you can implement few transitions in a PDF presentation using Acrobat Setting up PDFs for a presentation.
Regards,
Aadesh
Copy link to clipboard
Copied
Hioliver0541,
PowerPoint animations are not carry forwarded to the PDF. However you can implement few transitions in a PDF presentation using Acrobat Setting up PDFs for a presentation.
Regards,
Aadesh
Copy link to clipboard
Copied
Sub AddElements()
Dim shp As Shape
Dim i As Integer, n As Integer
n = ActivePresentation.Slides.Count
For i = 1 To n
Dim s As Slide
Set s = ActivePresentation.Slides(i)
s.SlideShowTransition.Hidden = msoTrue
Dim max As Integer: max = 0
For Each shp In s.Shapes
If shp.AnimationSettings.Animate = msoTrue Then
If shp.AnimationSettings.AnimationOrder > max Then
max = shp.AnimationSettings.AnimationOrder
End If
End If
Next
Dim k As Integer, s2 As Slide
For k = 0 To max
Set s2 = s.Duplicate(1)
s2.SlideShowTransition.Hidden = msoFalse
s2.MoveTo ActivePresentation.Slides.Count
Dim i2 As Integer
For i2 = s2.Shapes.Count To 1 Step -1
With s2.Shapes(i2)
If .AnimationSettings.Animate = msoTrue Then
If .AnimationSettings.AnimationOrder > k Then
.Delete
Else
.AnimationSettings.Animate = msoFalse
End If
End If
End With
Next
Next
Next
End Sub
Sub RemElements()
Dim i As Integer, n As Integer
Dim s As Slide
n = ActivePresentation.Slides.Count
For i = n To 1 Step -1
Set s = ActivePresentation.Slides(i)
If s.SlideShowTransition.Hidden = msoTrue Then
s.SlideShowTransition.Hidden = msoFalse
Else
s.Delete
End If
Next
End Sub
Go to your opened Power Point presentation, click on "Macros" and run "AddElements"
Now you can notice that the all original slides were "dimmed", and new slides were added. In newly created slides, the original slides with animations are duplicated.
Navigate to the "Save As" and select PDF as the target format
Copy link to clipboard
Copied
Thanks for sharing the macro. It works great! I am having trouble now, it is changing/corrupting the page numbering of some very large power point presentations. Any thoughts?
Copy link to clipboard
Copied
Belated thanks for this. Huge amount of time saved importing Powerponit into Premier via PNG rather thank video and chopping it up. Thankyou.
Copy link to clipboard
Copied
Used to work in powerpoint 2013 but the latest version creates an error at:
If shp.AnimationSettings.AnimationOrder > max Then
Why?
Copy link to clipboard
Copied
Hi,
Thanks for the solution.
From my side, I have one more issue that I have included Audio files as well alongwith the Animations. The Macro you mentioned certainly helps to show the slides one by one in PDF. But is there any way to play the Audio files as well in that PDF file ?
Thanks in advance.
Copy link to clipboard
Copied
Thank you so much, work like a charm.
Copy link to clipboard
Copied
Here is a tutorial that shows you how to convert the slides to PDF and keep the animation. Enjoy!
Convert an Animated PowerPoint Presentation to an Animated PDF - YouTube
Copy link to clipboard
Copied
http://neilmitchell.blogspot.com/2007/11/powerpoint-pdf-part-2.html
Use this script with office 365:
Option Explicit
Sub AddElements()
Dim shp As Shape
Dim i As Integer, n As Integer
n = ActivePresentation.Slides.Count
For i = 1 To n
Dim s As Slide
Set s = ActivePresentation.Slides(i)
s.SlideShowTransition.Hidden = msoTrue
Dim max As Integer: max = AnimationElements(s)
Dim k As Integer, s2 As Slide
For k = 1 To max
Set s2 = s.Duplicate(1)
s2.Name = "AutoGenerated: " & s2.SlideID
s2.SlideShowTransition.Hidden = msoFalse
s2.MoveTo ActivePresentation.Slides.Count
Dim i2 As Integer, h As Shape
Dim Del As New Collection
For i2 = s2.Shapes.Count To 1 Step -1
Set h = s2.Shapes(i2)
If Not IsVisible(s2, h, k) Then Del.Add h
Next
Dim j As Integer
For j = s.TimeLine.MainSequence.Count To 1 Step -1
s2.TimeLine.MainSequence.Item(1).Delete
Next
For j = Del.Count To 1 Step -1
Del(j).Delete
Del.Remove j
Next
Next
Next
End Sub
'is the shape on this slide visible at point this time step (1..n)
Function IsVisible(s As Slide, h As Shape, i As Integer) As Boolean
'first search for a start state
Dim e As Effect
IsVisible = True
For Each e In s.TimeLine.MainSequence
If e.Shape Is h Then
IsVisible = Not (e.Exit = msoFalse)
Exit For
End If
Next
'now run forward animating it
Dim n As Integer: n = 1
For Each e In s.TimeLine.MainSequence
If e.Timing.TriggerType = msoAnimTriggerOnPageClick Then n = n + 1
If n > i Then Exit For
If e.Shape Is h Then IsVisible = (e.Exit = msoFalse)
Next
End Function
'How many animation steps are there
'1 for a slide with no additional elements
Function AnimationElements(s As Slide) As Integer
AnimationElements = 1
Dim e As Effect
For Each e In s.TimeLine.MainSequence
If e.Timing.TriggerType = msoAnimTriggerOnPageClick Then
AnimationElements = AnimationElements + 1
End If
Next
End Function
Sub RemElements()
Dim i As Integer, n As Integer
Dim s As Slide
n = ActivePresentation.Slides.Count
For i = n To 1 Step -1
Set s = ActivePresentation.Slides(i)
If s.SlideShowTransition.Hidden = msoTrue Then
s.SlideShowTransition.Hidden = msoFalse
ElseIf Left$(s.Name, 13) = "AutoGenerated" Then
s.Delete
End If
Next
End Sub