PDG is continually astounded at how unhelpful and unintuitive Microsoft programs can be. But thankfully in this case, my not-uncommon gripe has a happy ending.
The unmet need, as framed as a typical google search query:
I want to export all of the text from a 20-page PowerPoint file to a plain text file.
Why? so that we can translate the text easily… or perhaps to proof read the text, or use the content in another medium, like in an email or Word document.
Out of thousands of hits, only 1 website solved the problem. I’ll share with you the solution next.
Thinking (wrongly) that surely PowerPoint 2008 for Mac lets us export the text from slides, I hunted for the option. First discovery: there is no export function. Okay, let’s try Save As… no, these options are useless, as the RTF outline text or HTML options do not export any slide text! Astounding. The “Outline” option requires some unusual structuring that ignores any actual content on the slides! And the “HTML” option actually flattens all the text into a graphic. Wow. Because in this SEO era, we surely don’t care about text-based content on our web pages, right?
I found one helpful web page out of thousands that had a solution. It involves running a simple macro snippet, after adding it to the PPT file. I have never used Macros before, but I was able to figure it out in under 5 minutes.
But this technique does not work for POWERPOINT:MAC 2008 — because Microsoft removed Macro support in Office 2008. Astounding again. Who does the thinking at the Mac Business Unit there? UPDATE: Macro support is back in Office 2011.
However, luckily, I also have Office 2004 for Mac. If you do too, follow along.
The website with the macro solution is here, at the PPT FAQ site. Credit to Stephen Rindsberg, who modified code from Kris Lander.
Copy the 2nd chunk of code. Here it is for you:
Dim oPres As Presentation
Dim oSlides As Slides
Dim oSld As Slide 'Slide Object
Dim oShp As Shape 'Shape Object
Dim iFile As Integer 'File handle for output
iFile = FreeFile 'Get a free file number
Dim PathSep As String
Dim FileNum As Integer
#If Mac Then
PathSep = ":"
PathSep = "\"
Set oPres = ActivePresentation
Set oSlides = oPres.Slides
FileNum = FreeFile
'Open output file
' NOTE: errors here if file hasn't been saved
Open oPres.Path & PathSep & "AllText.TXT" For Output As FileNum
For Each oSld In oSlides 'Loop thru each slide
For Each oShp In oSld.Shapes 'Loop thru each shape on slide
'Check to see if shape has a text frame and text
If oShp.HasTextFrame And oShp.TextFrame.HasText Then
If oShp.Type = msoPlaceholder Then
Select Case oShp.PlaceholderFormat.Type
Case Is = ppPlaceholderTitle, ppPlaceholderCenterTitle
Print #iFile, "Title:" & vbTab & oShp.TextFrame.TextRange
Case Is = ppPlaceholderBody
Print #iFile, "Body:" & vbTab & oShp.TextFrame.TextRange
Case Is = ppPlaceholderSubtitle
Print #iFile, "SubTitle:" & vbTab & oShp.TextFrame.TextRange
Print #iFile, "Other Placeholder:" & vbTab & oShp.TextFrame.TextRange
Print #iFile, vbTab & oShp.TextFrame.TextRange
End If ' msoPlaceholder
End If ' Has text frame/Has text
'Close output file
Now open the PPT file in PowerPoint:Mac 2004, open the menu item “Tools –> Macros” and you will see the Macro editor. It will be empty at first.
You will not see this macro like I show, at first; to begin, type in a simple name, then click CREATE.
Copy/paste the visual basic snippet into the new dialog/edit box that appears, then SAVE it.
Now you can RUN this macro. Voila. The exported txt file will be placed in the same directory as the PPT file itself.
It worked seamlessly, without a hitch.
And his script works for Mac and PC.
Try it out! it saved me lots of manual copy/paste time.