0 Replies Latest reply on Oct 8, 2011 2:23 PM by ajk1968

    AcroRd32 Opens and Then Closes when Invoked from VB in PowerPoint

    ajk1968

      Hi,

       

      I am trying to open a pdf file embedded in a PowerPoint presentation while in presentation mode.

      Theoretically, I should be able to click on the embedded object and have it open in its proper application.

      When I try to open a pdf file, AcroRd32 opens, briefly displays the document, and then closes immediately.

      This happens in both versions Acrobat Reader 9 and X. The problem didn't exist when using Office 2003, but now exists in Office 2007.

      I can open the document when in editing mode - just not in presentation mode.

       

      I have built an Add-In for PowerPoint.

       

      My VB code for opening the document is:

       

      myshape = applicationObject.ActiveWindow.Selection.SlideRange.Shapes.AddOLEObje ct( _

                      FileName:=vrtSelectedItem, Link:=MsoTriState.msoFalse, _

                      Left:=22.5, Top:=127, Width:=675.8, Height:=377)

      With myshape.ActionSettings(Powerpoint.PpMouseActivation.ppMouseClick)

                      .Action = Powerpoint.PpActionType.ppActionOLEVerb

                      .ActionVerb = "Open"

      End With

       

      Does anybody know how to fix this problem, or have a work-around for it?

       

      Thanks.