Re: Opening up files on a web server using window.open(file:///G:\

Tech-Archive recommends: Fix windows errors by optimizing your registry

From: Stephen (Stephen_at_discussions.microsoft.com)
Date: 09/28/04


Date: Tue, 28 Sep 2004 06:35:09 -0700

Yeah something like that I think, however im using c# so im not sure of this
code.

"McKirahan" wrote:

> "Stephen" <Stephen@discussions.microsoft.com> wrote in message
> news:D7CD60CA-23AD-4F53-B72F-F1310A878DA0@microsoft.com...
> > I was wondering if someone could give me some advise on a problem I have.
> At
> > present i have a web application which displays pdf files in a web browser
> > using javascript and the window.open method and pointing to a web address
> > like window.open(http://.........).
> > I have been asked to find out if it is possible to do something similar
> but
> > instead opening a file located on my web server e.g.(G:\psh-4.pdf). I
> would
> > like to be able to display the file in the web browser using the
> > window.open method again but this time pointing to the location on my web
> > server. I need to be able to open the file using something like:
> > window.open(file:///G:\phs-4.pdf).
> > Does anyone know if this is possible and if so has anyone any examples of
> > where this has been done before? Any explanations about how this works
> would
> > also be useful as I have to try and explain this.
> > Thanks in advance for any help anyone can give me.
>
> Like this?
>
> Option Explicit
> Const cVBS = "pdf_ie.vbs"
> Dim objIEA
> Set objIEA = CreateObject("InternetExplorer.Application")
> objIEA.Visible = True
> objIEA.Navigate "c:\temp\pdf_ie.pdf"
> While objIEA.Busy
> Wend
> Set objIEA = Nothing
>
>
>