Avatar of millikens
millikens
 asked on

Error when calling PowerPoint from Access

At the line of code [obj_PPointApp.Visible = True] that makes Powerpoint visible, the following error is reported :

"Error Number : -2147417848 - Automation eroor - The object invoked has disconnected from its clients"

Any suggestions on how to overcome this issue.
'   Local variable definition
Dim obj_PPointApp As PowerPoint.Application
Dim obj_PPointOpen As Boolean
 
On Error GoTo OpenPPointPres_Err
    
    '     Set new occurrance of PPoint
    Set obj_PPointApp = New PowerPoint.Application
    
    '     Test for outlook already open
    obj_PPointOpen = True
    Set obj_PPointApp = GetObject(, "PowerPoint.Application")
    
    '     If applicaton not open, then create application
    If obj_PPointApp Is Nothing Then
     Set obj_PPointApp = CreateObject("PowerPoint.Application")
          obj_PPointOpen = False
    End If
    
    '     Display application and then open document
    obj_PPointApp.Visible = True
    obj_PPointApp.Presentations.Open strDocName

Open in new window

Microsoft AccessMicrosoft PowerPoint

Avatar of undefined
Last Comment
harfang

8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
harfang

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
harfang

Silly MsgBox line... should be: MsgBox Err.Description
(°v°)
This is the best money I have ever spent. I cannot not tell you how many times these folks have saved my bacon. I learn so much from the contributors.
rwheeler23