?
Solved

VBA to convert PowerPoint 2007 to 2003

Posted on 2011-02-28
2
Medium Priority
?
711 Views
Last Modified: 2012-05-11
Hi,

I have a number of PowerPoint 2007 files in a directory, and would like to set up a VBA macro that converts them into PowerPoint 2003 files. But I can't find the code to do this. Here's where I've got to so far. The ppPowerPoint8 does not seem to work, although the Excel equivalent, xlExcel8, does.

Sub Convert2003()

a = MsgBox("Please browse to the relevant folder holding your .PPTX files", vbOKOnly, "Browse")
Set userDir = Application.FileDialog(msoFileDialogFolderPicker)
   
With userDir
    .Show
    'On Error GoTo here
    FolderName = .SelectedItems(1) & "\"
End With
    ChDrive FolderName
    ChDir FolderName
    fnames = Dir("*template phase 2.pptx")
    'determine the type of files we are going to be working with...
    Do While fnames <> ""
        Presentations.Open FileName:=fnames
        'save workbook in Ppt 2003 format
    Presentations(fnames).SaveAs FileName:=Left(fnames, Len(fnames) - 5), FileFormat:=ppPowerPoint8
               
    'close saved workbook
    Presentations(fnames).Close
    'loop to next file
        fnames = Dir()
    Loop
Exit Sub
'here:
End Sub
0
Comment
Question by:Tracey_Hill
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 59

Accepted Solution

by:
Chris Bottomley earned 1000 total points
ID: 34996552
It ought to save as 97-2003 if you simply use:

Presentations(fnames).SaveAs FileName:=Left(fnames, Len(fnames) - 5) & ".ppt"

Chris
0
 

Author Comment

by:Tracey_Hill
ID: 34996871
Yes that worked. Thanks!
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

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

This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.
PowerPoint is the go-to presentation software for millions of users around the world. Many presentations use basic text features but you can really make special text jump out of your slide by applying this bubble text design process. This article ha…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
The viewer will learn how to  create a slide that will launch other presentations in Microsoft PowerPoint. In the finished slide, each item launches a new PowerPoint presentation and when each is finished it automatically comes back to this slide: …
Suggested Courses

777 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