Slide names lost after exit and reopening

  • Thread starter Thread starter MeSteve
  • Start date Start date
M

MeSteve

I am setting slide names:

Set pptSlide(i) = ActivePresentation.Slides.Add(i, ppLayoutBlank).name =
"Front" & i

&

Set pptSlide(i) = ActivePresentation.Slides.Add(i, ppLayoutBlank)
With pptSlide(i)
.Name = "Front" & i
End With

If I close the .ppt and reopen, the names are not being stored. I have some
code that looks for and deletes the slides I am making and then recreates
them with new data. Any ideas what I am missing? Thanks.
 
All 3 solutions name the slide correctly. The problem is, that if I close
the file and reopen it, the slides are named Slide2 and Slide3 (I have a
control slide for formatting setup, Slide1). Then,
ActivePresentation.Slides("Front" & i).Delete doesn't find the slides I ma
trying to delete.
 
Doesn't help I know but it works fine here (2003). Save and open makes no
difference.

Have you thought of using tags to identify the slides to be deleted?

..Tags.Add "delete", "yes"

then iterate through the slides (in reverse order)
for i= ActivePresentation.Slides.Count To 1 Step -1
with ActivePresentation.Slides(i)
If .Tags("delete")="yes" then .Delete
End With
Next i
--
Amazing PPT Hints, Tips and Tutorials

http://www.PPTAlchemy.co.uk
http://www.technologytrish.co.uk
email john AT technologytrish.co.uk
 
Back
Top