Displaying a .PDF File

JACKSON

Registered User.
Local time
Today, 20:53
Joined
Dec 22, 2003
Messages
79
I am having a proble displaying a .pdf file on a command button action.

Here is the part of my code that calls up the file:

Dim StrProg As String
Dim StrFile As String

StrProg = "C:\Program Files\Adobe\Acrobat 7.0\Reader.exe"
StrFile = "C:\Program Files\Polaris Medical Chart Ver3.3\example.pdf"

Shell StrProg & StrFile, vbNormalFocus

Exit Sub


I get a file not found error. Any thoughts??

Thanks
 
G'day Jackson,

When I checked the filename for the exe file for Adobe 7.0 it shows as being acrord32.exe not sure whether this is your problem or not.... Just a thought.

Regards
 
Thanks

That was defiantely a problem, but I am still geting the same error message about file not being found. I have re-checked my dir paths. Does my shell command look OK ??
 
Currently your:
Shell StrProg & StrFile, vbNormalFocus

Will yield:
StrProg = "C:\Program Files\Adobe\Acrobat 7.0\Reader.exeC:\Program Files\Polaris Medical Chart Ver3.3\example.pdf"

So I'm assuming you need to revise to add a space:

Shell StrProg & " " & StrFile, vbNormalFocus
 

Users who are viewing this thread

Back
Top Bottom