[dba-VB] Open PDF file

Jim Hewson JHewson at karta.com
Mon Nov 26 08:37:38 CST 2007

Doesn't the PDF reader need to be on the user's machine?
How does this open a file on a server so the user, presumably somewhere else, open the file and review it?
I thought the user must have Adobe reader on their machine.

jhewson at karta.com
-----Original Message-----
From: dba-vb-bounces at databaseadvisors.com [mailto:dba-vb-bounces at databaseadvisors.com] On Behalf Of Gustav Brock
Sent: Monday, November 26, 2007 7:43 AM
To: dba-vb at databaseadvisors.com
Subject: Re: [dba-VB] Open PDF file

Hi David

This works for me having Acrobat Reader as the default viewer in Windows:

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
        Dim runPdf As New System.Diagnostics.Process
        Dim fileName As String = "c:\test.pdf"

        runPdf.StartInfo.FileName = fileName
        runPdf.StartInfo.WindowStyle = ProcessWindowStyle.Normal

        runPdf = Nothing
    End Sub


>>> newsgrps at dalyn.co.nz 26-11-2007 06:14 >>>
I am using VS 2005 and VB.Net for a web site.

I have a number of PDF files that are stored in a static folder on the server.

Users select from a list on files on a web page and I want to open 
the files in Adobe.  Adobe reader is installed on the server.

Can anyone give me a pointer to how I can take a string with path and 
file name, and open it?


David Emerson
Dalyn Software Ltd
Wellington, New Zealand 

dba-VB mailing list
dba-VB at databaseadvisors.com

More information about the dba-VB mailing list