Hi all,
Is there a way to have MS Access open a .pdf in Adobe Acrobat? My client has this situation but his document opens in Adobe Reader. He's trying to open the .pdf using a hyperlink. As always, any and all suggestions are appreciated.
Bill
Open pdf in Adobe Acrobat not Reader
-
- Lounger
- Posts: 47
- Joined: 09 Feb 2010, 11:30
- Location: OH USA
-
- Administrator
- Posts: 78625
- Joined: 16 Jan 2010, 00:14
- Status: Microsoft MVP
- Location: Wageningen, The Netherlands
Re: Open pdf in Adobe Acrobat not Reader
If Adobe Reader is set as the default application for .pdf files, a hyperlink to a PDF file will open Reader. To open a PDF file in Adobe Acrobat, you have to do so explicitly, e.g.
Shell """%programfiles%\adobe\acrobat.exe"" ""C:\MyFolder\MyFile.pdf"""
Note the use of double quotes within the string.
Shell """%programfiles%\adobe\acrobat.exe"" ""C:\MyFolder\MyFile.pdf"""
Note the use of double quotes within the string.
Best wishes,
Hans
Hans
-
- Lounger
- Posts: 47
- Joined: 09 Feb 2010, 11:30
- Location: OH USA
Re: Open pdf in Adobe Acrobat not Reader
Thanks Hans. We'll give it a try.
-
- Lounger
- Posts: 47
- Joined: 09 Feb 2010, 11:30
- Location: OH USA
Re: Open pdf in Adobe Acrobat not Reader
I tried the suggestion and received the following message:
Unable to open Shell """%programfiles%\adobe\acrobat.exe"" ""I:/Stewardship/Griggs/Dublin_Road/Scanned_Documents_4440 Dublin.pdf"""
Unable to open Shell """%programfiles%\adobe\acrobat.exe"" ""I:/Stewardship/Griggs/Dublin_Road/Scanned_Documents_4440 Dublin.pdf"""
-
- Administrator
- Posts: 78625
- Joined: 16 Jan 2010, 00:14
- Status: Microsoft MVP
- Location: Wageningen, The Netherlands
Re: Open pdf in Adobe Acrobat not Reader
The path to the PDF file should contain backslashes \ instead of forward slashes /.
If that doesn't help, check the path where Adobe Acrobat is installed, and modify the path %programfiles%\adobe accordingly.
If that doesn't help, check the path where Adobe Acrobat is installed, and modify the path %programfiles%\adobe accordingly.
Best wishes,
Hans
Hans
-
- Lounger
- Posts: 47
- Joined: 09 Feb 2010, 11:30
- Location: OH USA
Re: Open pdf in Adobe Acrobat not Reader
Tried the path with backslashes \ with the same results. After the message displays, I go to edit the hyperlink and the backslashes \ were changed to forward slashes /.
-
- Administrator
- Posts: 78625
- Joined: 16 Jan 2010, 00:14
- Status: Microsoft MVP
- Location: Wageningen, The Netherlands
Re: Open pdf in Adobe Acrobat not Reader
I'm sorry, I haven't been sufficiently clear. The line that I posted wasn't intended to be entered in the Hyperlink property of a control. It is a VBA line of code to be used in the On Click event of a command button, e.g. if you have a button named cmdOpenPDF:
Code: Select all
Private Sub cmdOpenPDF_Click()
Shell """%programfiles%\adobe\acrobat.exe"" ""C:\MyFolder\MyFile.pdf"""
End Sub
Best wishes,
Hans
Hans
-
- Lounger
- Posts: 47
- Joined: 09 Feb 2010, 11:30
- Location: OH USA
Re: Open pdf in Adobe Acrobat not Reader
Thanks Hans. We'll try that tomorrow and let you know.
-
- Lounger
- Posts: 47
- Joined: 09 Feb 2010, 11:30
- Location: OH USA
Re: Open pdf in Adobe Acrobat not Reader
What I had to do was reinstall Adobe Acrobat and make it the default for .pdf files. It worked. Thanks much for your assistance.
Bill K
Bill K
-
- Administrator
- Posts: 78625
- Joined: 16 Jan 2010, 00:14
- Status: Microsoft MVP
- Location: Wageningen, The Netherlands
Re: Open pdf in Adobe Acrobat not Reader
So I presume you can now simply enter the file name (and path) in the Hyperlink property again.
Best wishes,
Hans
Hans
-
- Lounger
- Posts: 47
- Joined: 09 Feb 2010, 11:30
- Location: OH USA
Re: Open pdf in Adobe Acrobat not Reader
Yes, that is correct.