Microsoft Office Forums

Go Back   Microsoft Office Forums > >

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #1  
Old 04-11-2012, 10:34 AM
CatMan CatMan is offline Excel VBA to automate PowerPoint Windows 7 32bit Excel VBA to automate PowerPoint Office 2010 32bit
Intermediate
Excel VBA to automate PowerPoint
 
Join Date: Apr 2012
Posts: 39
CatMan is on a distinguished road
Default Excel VBA to automate PowerPoint

Hello Forum, thank you for taking the time to look at this.



In an Excel module (Excel is host) I am opening an existing PPT like this:

Code:
Dim ppte As Object
Dim oPAe As PowerPoint.Application
Dim oPPe As PowerPoint.Presentation
Dim oPSe As PowerPoint.Slide
Dim oShapee As PowerPoint.Shape
Dim oPicturee As PowerPoint.Shape
 
With ppt  <--this is a typo, should be 'with ppte' as explained 2 threads down)
    .Visible = True
    .Presentations.Open ("C:\Users\User\Documents\MyPPT.ppt")
End With
Next I want to activate a user defined slide, the following code works ok as a PowerPoint macro:

Code:
ActiveWindow.View.GotoSlide 3 'works inside ppt
but not inside the Excel module:

Code:
With ppte
       .View.GotoSlide 11
End With
I get a run-time error (429). I notice I am not referencing the slide object (oPSe) but all my attempts to work this have failed.

Last edited by CatMan; 04-11-2012 at 04:59 PM.
Reply With Quote
 



Similar Threads
Thread Thread Starter Forum Replies Last Post
Automate Office Attendance kgwack Outlook 0 02-14-2012 09:39 AM
Powerpoint/Excel richiejjj PowerPoint 0 02-09-2012 07:20 AM
How to automate all slides Pemberton PowerPoint 1 11-09-2011 04:39 PM
Automate Data from Excel into Word DropDown...? sigraves Word VBA 0 08-03-2009 06:54 AM
Automate Excel tabname deegz Excel 2 12-08-2008 02:57 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 04:38 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft