JavaScript Open PDF

Larry Brister
Larry Brister used Ask the Experts™
on
Is there a javaScript where I can force my RadGrid link button to open a PDF with Adobe and not in the Browser?
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
IT Expert
Top Expert 2009
Commented:
Not likely.

If you serve the file with
content-type application/octet-stream
the user will be prompted to open or save the file
Most Valuable Expert 2012
Top Expert 2014

Commented:
Its a user preference in browser which you can not change unless you send the PDF file as a stream, as suggested above, instead of a link.
Larry Bristersr. Developer

Author

Commented:
Thanks

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial