I have this code but it does not work since the code is in a Module. The error is
SlideshowWindows (unknown member): integer out of range. 1 is not in the valid range of 0-1
on yellow line below
How can I have a button on the "Quick access toolbar" point to code that is not dependent on which presentation is open?
I want to print the current slide by clicking a botton on the quick access toolbar.
TIA
SlideshowWindows (unknown member): integer out of range. 1 is not in the valid range of 0-1
on yellow line below
How can I have a button on the "Quick access toolbar" point to code that is not dependent on which presentation is open?
I want to print the current slide by clicking a botton on the quick access toolbar.
TIA
Code:
' This code determines what slide is currently visible in the
' slide show and then it clears the print range and prints out the
' current slide.
Sub PrintCurrentSlide()
' Declare lSldNum as a long integer.
Dim lSldNum As Long
' Assign lSldNum to the current slide number.
[highlight #FCE94F]lSldNum = SlideShowWindows(1).View.Slide.SlideNumber[/highlight] ' Set the print options for the active presentation.
With ActivePresentation.PrintOptions
' Set RangeType to print a slide range.
.RangeType = ppPrintSlideRange
' Delete old print range settings.
.Ranges.ClearAll
' Set Ranges to the new range for the current slide.
.Ranges.Add lSldNum, lSldNum
End With
ActivePresentation.PrintOut
End Sub
[/code
DougP