Click here to Skip to main content
15,038,345 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:

I want to open PDF file in
Path something like : http://localhost:1504/ABC/123.pdf

I want to Block Mouse and Keyborad on this PDF File.

how can I do ?.

Please Help me..
Nathan Minier 27-Oct-14 7:40am
How are you presenting the file (iframe, new window, etc)? What have you tried so far?

1 solution

There is no "mouse movement and keyboard" in a PDF file. PDF file is a document. :-)

More seriously, there is no such thing as "open PDF file in ASP.NET". PDF files can be opened in browser, but this is not standardized. PDF is not a part of W3 standards. So, it all depends on browser, usually implemented in some plug-ins and this feature is never guaranteed. That's right, you should never assume that PDF can be opened in a browser. It's quite possible to face a system without any PDF viewer at all. The only guaranteed possibility is to save a document in a file, which is not a problem at all, because anyone can save it and view later.

But the most important things is: if it was really possible to do what you want, it would became a huge abuse and unacceptable limitation of most basic customer's rights. It's only good that you don't have such possibility. Of course, you could create your own browser plug-in with such "feature", but who would like to use it? It would be the same as addressing to some people under arrest with advertizement of handcuffs. :-)

[no name] 27-Oct-14 9:28am
Nice one Sir. :)
Thank you, Suraj.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900