Link Button

johnob

Registered User.
Local time
Today, 07:51
Joined
Jan 12, 2014
Messages
45
Hi all,

I have a Adobe PDF Reader , active x control loaded on a form. And would like it to show the PDF a file when a button is clicked.

The following code works, if you want to view outside access, but I don't. Can anyone have a look and tell me how I can link the button to the active x component .

I keep getting an error with Set oApp = ([AcroPDF5])

Code:
Private Sub ViewPDFButton_Click()
 Dim oApp As Object

 Set oApp = ([AcroPDF5])
 oApp.Visible = True
 oApp.ChangeFileOpenDirectory "D:"
 oApp.Documents.Open FILENAME:=Me.ViewReportDetails & " "

 End Sub
Thank you
 

Users who are viewing this thread

Back
Top Bottom