Q: open a pdf file

G

Guest

Hello,
How can I check if a PDF file available under ApplicationPath\Doc\ folder in
the server and if yes, open it in the internet explorer.
Thanks,
Jim.
 
H

Hans Kesting

JIM.H. said:
Hello,
How can I check if a PDF file available under ApplicationPath\Doc\
folder in the server and if yes, open it in the internet explorer.
Thanks,
Jim.

check if exists:
System.IO.File.Exists(...)

upload to browser
Response.WriteFile(...)
(don't forget to set the ContentType, and maybe you need a Response.Clear
before and a Response.End after this)

Hans Kesting
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,432
Messages
2,571,680
Members
48,796
Latest member
Greg L.

Latest Threads

Top