1 | initial version |
You can use the following steps to rearrange slides using Excel VBA:
Sub RearrangeSlides()
Dim pptApp As PowerPoint.Application Dim pptPres As PowerPoint.Presentation
Set pptApp = New PowerPoint.Application Set pptPres = pptApp.Presentations.Open("c:\path\to\presentation.pptx")
pptPres.Slides(2).MoveTo pptPres.Slides.Count
You can rearrange multiple slides by repeating this code for each slide you want to move.
Finally, add the code to save and close the presentation:
pptPres.Save pptPres.Close pptApp.Quit
End Sub
Your PowerPoint presentation should now have the slides rearranged according to your code.