Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Renumber objects in a Powerpoint Document

Posted on 2013-12-10
2
Medium Priority
?
672 Views
Last Modified: 2013-12-10
I have a PowerPoint document that consists of many pages(slides) of images and on each slide there are several numbered images - the numbers are contained within a circle shape added with the Insert-Shape option.

Occasionally I will insert and or remove slides and move images around.

Is there a way to automatically renumber the images?

I'm assuming that it must be possible to write a macro that starts at the beginning, searches for each circle shape in turn an replaces the text.

I've attached a sample, the real document is currently 50+ slides.

I'm using PowerPoint 2013 by the way.
sample.pptx
0
Comment
Question by:KCTS
2 Comments
 
LVL 53

Accepted Solution

by:
Rgonzo1971 earned 2000 total points
ID: 39708300
Hi,

pls try

Sub Macro()

Idx = 1
For Each sld In ActivePresentation.Slides
    For Each Shp In sld.Shapes
        If Shp.AutoShapeType = msoShapeOval Then
            Shp.TextFrame.TextRange.Text = CStr(Idx)
            Idx = Idx + 1
        End If
    Next
Next
End Sub

Open in new window

Regards
0
 
LVL 70

Author Closing Comment

by:KCTS
ID: 39709196
Great - does exactly what I need - thank you
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Lost Word File? Eagerly, need it back? Read ahead; this File Recovery guide is for you.
Windows Explorer lets you open cabinet (cab) files like any other folder. In VBA you can easily handle normal files and folders, but opening and indeed creating cabinet files takes a lot more - and that's you'll find here.
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

971 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question