B
Bob
Hi,
I am trying to automatically update Layouts for all our presentations.
The follwoing code works great when stepped through line by line, but
produces nothing when run:
Sub SlideDesign()
On Error Resume Next
Dim oSld As Slide
ActivePresentation.ApplyTemplate FileName:=Environ("APPDATA") &
"\Microsoft\Templates\Blank.potx"
ActivePresentation.Tags.Add "TemplateVersion", "Vers3"
ActivePresentation.Tags.Add "AutoFooter", "on"
For Each oSld In ActivePresentation.Slides
oSld.CustomLayout = oSld.CustomLayout
Application.CommandBars.ExecuteMso ("SlideReset") ' Does same as
above, should be redundant in theory...
Next oSld
End Sub
Very strange!
Any thoughts:
- forcing a refresh?
- pausing?
- running through all the objects?
Thanks,
Bob
I am trying to automatically update Layouts for all our presentations.
The follwoing code works great when stepped through line by line, but
produces nothing when run:
Sub SlideDesign()
On Error Resume Next
Dim oSld As Slide
ActivePresentation.ApplyTemplate FileName:=Environ("APPDATA") &
"\Microsoft\Templates\Blank.potx"
ActivePresentation.Tags.Add "TemplateVersion", "Vers3"
ActivePresentation.Tags.Add "AutoFooter", "on"
For Each oSld In ActivePresentation.Slides
oSld.CustomLayout = oSld.CustomLayout
Application.CommandBars.ExecuteMso ("SlideReset") ' Does same as
above, should be redundant in theory...
Next oSld
End Sub
Very strange!
Any thoughts:
- forcing a refresh?
- pausing?
- running through all the objects?
Thanks,
Bob