Mississippi Girl
Board Regular
- Joined
- Oct 27, 2005
- Messages
- 155
We have a file that is generated in Excel, linked in to PowerPoint, and now the lovely folks above all of us worker-bees want to view their specific PowerPoint slides in PDF, but they do not want to have to be bothered looking at anyone else's information.
I have the following that saves each slide as it's own PDF file, but I don't really need every slide in the presentation. How can I allow the person running the module to select the slides that need to be PDF'd? Since the range of slides can vary from month to month, I was thinking a message box with the starting and ending slide numbers, but I'm not sure how to do that. Can you help??
I have the following that saves each slide as it's own PDF file, but I don't really need every slide in the presentation. How can I allow the person running the module to select the slides that need to be PDF'd? Since the range of slides can vary from month to month, I was thinking a message box with the starting and ending slide numbers, but I'm not sure how to do that. Can you help??
Code:
Sub ExportSlidesToIndividualPDF()
Dim oPPT As Presentation, oSlide As Slide
Dim sExt As String
Set oPPT = ActivePresentation
sExt = ".pdf"
For Each oSlide In oPPT.Slides
i = oSlide.SlideNumber
oSlide.Select
oPPT.ExportAsFixedFormat _
Path:="N:\_BA21.N\CFO Monthly Status\PDF Files\" & "_Slide_" & i & sExt, _
FixedFormatType:=ppFixedFormatTypePDF, _
RangeType:=ppPrintSelection
Next
Set oPPT = Nothing
End Sub