Consulting

Results 1 to 3 of 3

Thread: Remove all Animations and Transitions with Macro

  1. #1

    Question Remove all Animations and Transitions with Macro

    Hi,

    New user here with little VBA macro code experience. I'm struggling with modifying the excellent code from TheSpreadshhetGuru that removes all my animations.

    I would like the macro to also remove all transitions in my Powerpoint and set manual advance. I google some code, but struggling to tie it into the code from TSG? Any help would be appreciated:-)

    .SlideShowTransition.EntryEffect = ppEffectNone
    .SlideShowTransition.AdvanceOnTime = msoFalse



    Sub RemoveAllAnimations()
    'PURPOSE: Remove All PowerPoint Animations From Slides
    'SOURCE: www.TheSpreadsheetGuru.com/the-code-vault
    
    Dim sld As Slide
    Dim x AsLong
    Dim Counter AsLong
    
    'Loop Through Each Slide in ActivePresentation
    ForEach sld In ActivePresentation.Slides
    
    'Loop through each animation on slide
    For x = sld.TimeLine.MainSequence.Count To 1 Step -1
    
    'Remove Each Animation
              sld.TimeLine.MainSequence.Item(x).Delete
    
    'Maintain Deletion Stat
              Counter = Counter + 1
    
    Next x
    
    Next sld
    
    'Completion Notification
    MsgBox Counter & " Animation(s) were removed from you PowerPoint presentation!"
    
    EndSub

  2. #2
    VBAX Master
    Joined
    Feb 2007
    Posts
    1,963
    Location
    Try

    Sub RemoveAllAnimations()
    'PURPOSE: Remove All PowerPoint Animations From Slides
    'SOURCE: www.TheSpreadsheetGuru.com/the-code-vault
    
    
    Dim sld As Slide
    Dim x As Long
    Dim Counter As Long
    
    
    'Loop Through Each Slide in ActivePresentation
    For Each sld In ActivePresentation.Slides
    'Loop through each animation on slide
    For x = sld.TimeLine.MainSequence.Count To 1 Step -1
    
    
    'Remove Each Animation
              sld.TimeLine.MainSequence.Item(x).Delete
    'Maintain Deletion Stat
              Counter = Counter + 1
    Next x
    sld.SlideShowTransition.AdvanceOnTime = False
    sld.SlideShowTransition.AdvanceOnClick = True
    sld.SlideShowTransition.EntryEffect = ppEffectNone
    Next sld
    
    
    'Completion Notification
    MsgBox Counter & " Animation(s) were removed from you PowerPoint presentation!"
    
    
    End Sub
    John Wilson
    Microsoft PowerPoint MVP
    Amazing Free PowerPoint Tutorials
    http://www.pptalchemy.co.uk/powerpoi...tutorials.html

  3. #3

    Wink

    Thanks a lot John for your swift reply and resolution:-) This one seem to do the trick

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •