views:

360

answers:

2

I have to display a PDF inside a winform (c# on .net 2.0 framework). For now, I am using the ActiveX PDF control provided by Adobe. I have to disable the entire control so that a user can't print or save via right-click or hotkeys. Unfortunately, many of the documents need to be rotated (just viewed, not permanently saved that way). I'd like to allow them to rotate the view by pressing a button control. I've tried enabling the control then programmatically sending the hotkeys (ctrl shift +) using SendKeys and SendInput but the timing issues make this a non-viable solution.

I've asked on the proper Adobe boards and they said it was not possible being that all of my clients will only have the reader version installed.

A: 

I don't suppose you could put controls on the PDF that prevent saving and printing?

jasonh
If I allow the user to focus the control, they could right either hit the print/save icons, right click, or ctrl+P. Also, using this activex control, there is no way to disable print or save.
Dabas
I'm talking about enabling the controls on the PDF itself for preventing print and save. Sorry for being unclear. There is a way to flag the PDF as being disallowed for printing and saving, and Adobe's PDF software obeys these flags.
jasonh
Unfortunately, there is no way to disable print or save with the activex control.
Dabas
There is a "ShowToolbar" but that is all or nothing. I still need the user to be able to use the zoom/rotate commands.
Dabas
+1  A: 

just rotate the control. put the control in a panel and rotate the panel or something.

cferbs
if that is possible. i have never looked into it
cferbs
there is also this project i found on google code that uses xpdf and mupdf to display pdf files in winforms so you could use that library to render the pdf and make your own contorl. http://code.google.com/p/pdfviewer-win32/
cferbs