programming with powerpoint

  • Thread starter Thread starter JulieD
  • Start date Start date
J

JulieD

i'm new to programming with powerpoint although i've had plenty of
experience with excel etc ... is it possible (and if so, how do i approach
the following)

i have 26 powerpoint presentations (a.ppt ... z.ppt), i would like to open
each in turn, and print handouts (9 to a page, with the filename & page
number shown in the footer) and then close that file - saving it & open the
next.

cheers
JulieD
 
There are some good sources to start to learn VBA at:
**How do I USE this VBA stuff in PowerPoint?
http://www.rdpslides.com/pptfaq/FAQ00033.htm

and the ever popular,
**How do I USE this VBA stuff in PowerPoint?
http://www.rdpslides.com/pptfaq/FAQ00033.htm

Try these. If you run into a problem, post back your question and we'd be
glad to answer it.


--
Bill Dilworth, Microsoft PPT MVP
===============
Please spend a few minutes checking vestprog2@
out www.pptfaq.com This link will yahoo.
answer most of our questions, before com
you think to ask them.

Change org to com to defuse anti-spam,
ant-virus, anti-nuisance misdirection.
..
..
 
Julie,
This macro will open each presentation in the collection and print it.
' ---------Begin Block------------
Sub PrintHandouts()
Dim FilesToPrint As Collection
Dim oPresToPrint As Presentation
Dim iCtr As Integer

' Create list of presentations to print.
Set FilesToPrint = New Collection
FilesToPrint.Add "E:\Documents and Settings\Shyam\My Documents\a.ppt"
FilesToPrint.Add "E:\Documents and Settings\Shyam\My Documents\b.ppt"
FilesToPrint.Add "E:\Documents and Settings\Shyam\My Documents\c.ppt"

For iCtr = FilesToPrint.Count To 1 Step -1
' Open the presentation but without a window.
Set oPresToPrint = Presentations.Open(FilesToPrint(1), , , False)
If Not oPresToPrint Is Nothing Then
With oPresToPrint.PrintOptions
.OutputType = ppPrintOutputNineSlideHandouts
.HandoutOrder = ppPrintHandoutHorizontalFirst
' Comment this line if you want to send to default printer
.ActivePrinter = "Microsoft Office Document Image Writer"
.RangeType = ppPrintAll
.PrintHiddenSlides = False
' Set other print properties of choice here
' ----
End With
oPresToPrint.PrintOut
oPresToPrint.Close
End If
FilesToPrint.Remove 1
Next iCtr
Set oPresToPrint = Nothing
Set FilesToPrint = Nothing
End Sub
' ---------- End Block -----------
 
Back
Top