handle message when automatically opening other app

camg12

Registered User.
Local time
Today, 08:59
Joined
Jan 5, 2010
Messages
18
I am trying to automate the process of getting data from Access to PowerPoint. I am using the following code to open PowerPoint. When PowerPoint opens though I get a warning message. How do I add a function into my code to select the "Update" button?

Private Sub CmdOpenPowerPoint_Click()
'WillR - opens the specified Spreadsheet
Dim PPApp As PowerPoint.Application
Dim PPSlide As PowerPoint.Slide
Set PPApp = New PowerPoint.Application
With PPApp
.Visible = True
Set PPSlide = .Presentations.Open("test.pptx", , False)
End With
End Sub


 
I ended up using the SendKey function and that worked.
 
Investigate the CreateObject function. I think it's more reliable.
 

Users who are viewing this thread

Back
Top Bottom