View Single Post
  #7  
Old January 15th, 2005, 04:49 PM
Steve Rindsberg
external usenet poster
 
Posts: n/a
Default

In article , MS MVP Brian Reilly
wrote:
Jeff,
Here's another piece of code in addition to Steve's that I use all the
time as a wrapper to iterate through all shapes on all slides. Note,
I've commented out the section that you can change exactly what you
do, but the top and bottom parts are the iteration code.


Brian reformats his hard drive quite often. Chances are he lost his mind the
last time he did it. It's one of those pesky hidden files, ya know?

Sub DiddleAllTheShapes()

Dim oSh as Shape
Dim oSl as Slide

' Look at each slide
For Each oSl in ActivePresentation.Slides
' Look at each shape on the slide
For each oSh in oSl.Shapes
' Do whatever you need to with the shape
With oSh
Debug.Print .Name
.Left = .Left + 10
' .Whatever
End With ' The shape
Next ' Shape
Next ' Slide

End Sub

-----------------------------------------
Steve Rindsberg, PPT MVP
PPT FAQ: www.pptfaq.com
PPTools: www.pptools.com
================================================