Link to home
Start Free TrialLog in
Avatar of MonteDelMar
MonteDelMar

asked on

Control PowerPoint 2007 from Word - VBA, Themes & Customise Handout Master

Hi Experts

I am trying to control PowerPoint from Word.  

I have created a customised template including a customised Handouts master.  I set everything up as I want it to be and have created a Theme.

When I create the presentation manually from PowerPoint by clicking New and choosing the customised template, the Handout master is formatted as I want it to be.  However, if I create the presentation from Word or if I create a presentation directly from PowerPoint based on the default template (i.e. Office Button & New & Blank Presentation) and apply the Theme to it then the Handout master format returns to the un-customised version.  I thought perhaps that I needed to apply the Theme to the Handout master seperately but with the Handout master open, if I click the 'Themes' button, all Themes are greyed out.

I am defintely getting a headache now :-(

Please can somebody tell me where I am going wrong with this?  The code I am using to create the presentation is attached.  

Thank you very much for your help.

Sub TryThis()
Dim oPPT As PowerPoint.Application
Dim oPres As PowerPoint.Presentation

Set oPPT = New PowerPoint.Application
oPPT.Visible = msoTrue

Set oPres = oPPT.Presentations.Add(msoTrue)
oPres.ApplyTemplate "c:\MySetup\MyStandard.potm"

Set oPPT = Nothing
Set oPres = Nothing
End Sub

Open in new window

ASKER CERTIFIED SOLUTION
Avatar of Echo_S
Echo_S
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of MonteDelMar
MonteDelMar

ASKER

Many thanks for your reply.

I wonder if there is another way to create the presentation via code that is effectively 'File New' based on the required template rather than applying it as I am doing now.
Thank you.  I think the answer does lie in the fact that this feature is buggy.  I just wonder if there are some ways around the various problems it causes in VBA.  Am going to post some specific VBA questions.