deleting blamk slides on mass

M

Matt

I was wondering if anyone could help me. I have an application which
generates a powerpoint presentation based on the information entered into the
database. However many blank slides are generated and I would like to delete
them en mass. Is there any way I can delete blank slides all in one go
instead of having to work my way through the presentation and deleting them
separately.
 
M

Michael Koerner

Matt;

If you go into the slide sorter view. You can select all your blank slides
at once and delete them. You might write a macro to go throug the
presentation, and delete all blank slides

Michael Koerner
MS PPT MVP
 
M

Matt

That is what I was after Michael. I have some over two hundred blank slides
generated and would like to know how I could write this macro. Any tips?
Matthew
 
S

Shyam Pillai

Matt,
What defines a blank slide for you? A slide with no shapes? A slide with
blank placeholder? It's a straightforward macro. If you fill in the
information I will post the code.


--
Regards,
Shyam Pillai

Image Importer Wizard: http://skp.mvps.org/iiw.htm
 
M

Matt

A blank slide is exactly that. Just a blank slide with absolutely nothing on
it. No text, no graphics, nothing --- just a blank or maybe better described
as an empty slide.

Thank you very much Shyam. I truly appreciate your help. I know very little
about macro writing and would like to do a course or something eventually. It
seems the way to go.

Could you write the code so that I have a button, or menu item that I can
assign to it as a permanent fixture in powerpoint?
It will be used a lot.

Thank yo so much again

Matthew
 
S

Shyam Pillai

Sub DeleteEmptySlides()
Dim oSld As PowerPoint.Slide
Dim I As Integer
For I = ActivePresentation.Slides.Count To 1 Step -1
If ActivePresentation.Slides(I).Shapes.Count = 0 Then
ActivePresentation.Slides(I).Delete
End If
Next
End Sub
 
D

David M. Marcovitz

He sent me email, and I sent him almost the identical code. Then, he
confessed to me that the slide is not totally blank. He discovered that
it has an empty shape on it. So, my question to him was how can the
computer (not an intelligent human) tell that the slide is "blank" and
needs to be deleted. He hasn't responded yet.
--David

--
David M. Marcovitz
Microsoft PowerPoint MVP
Director of Graduate Programs in Educational Technology
Loyola College in Maryland
Author of _Powerful PowerPoint for Educators_
http://www.loyola.edu/education/PowerfulPowerPoint/
 
E

Echo S

Nothing like having both of you waste your time on the same problem.
<shaking head>

This is why I usually don't respond to email requests for assistance.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top