Hi,

Greetings!

We are using iText to generate the pdf file, and show in the browser as part of 
preview.

We are facing a challenge of disabling the print, save pdf file from the 
browser, this is client requirement to protect the document, this should be 
only viewable, but not to download/save and print directly.

Please suggest us on this as how we can achieve this.

Currently I am using the below two code snippets, to disable the toolbar, it 
works fine in IE browser, but not in other browsers like, Chrome and FireFox.


1.       Appending the #toolbar=0&navpanes=0 at the end of the url, of the 
pdf file.

2.       Adding encryption using setEncryption() method of PDFstamper

pdfStamper.setEncryption(null, null, PdfWriter.ALLOW_SCREENREADERS, 
PdfWriter.DO_NOT_ENCRYPT_METADATA);


please let us know if you have any workaround to achieve this.


Thanks & Regards,
Shivaji Dole,
Infosys Limited, SEZ , Hyderabad.
T: +91 40 30968059(Ext: 68059)
M: +91 8008 456 457
[cid:image002.png@01CE8E9E.FEB27BD0]
Stay Connected  [cid:image003.gif@01CE8E9E.FEB27BD0] 
<https://twitter.com/Infosys>   [cid:image004.gif@01CE8E9E.FEB27BD0] 
<http://www.linkedin.com/company/1283>   [cid:image005.gif@01CE8E9E.FEB27BD0] 
<http://www.youtube.com/InfosysTechnologies>   
[cid:image006.gif@01CE8E9E.FEB27BD0] <http://www.slideshare.net/Infosys>



**************** CAUTION - Disclaimer *****************
This e-mail contains PRIVILEGED AND CONFIDENTIAL INFORMATION intended solely
for the use of the addressee(s). If you are not the intended recipient, please
notify the sender by e-mail and delete the original message. Further, you are 
not
to copy, disclose, or distribute this e-mail or its contents to any other 
person and
any such actions are unlawful. This e-mail may contain viruses. Infosys has 
taken
every reasonable precaution to minimize this risk, but is not liable for any 
damage
you may sustain as a result of any virus in this e-mail. You should carry out 
your
own virus checks before opening the e-mail or attachment. Infosys reserves the
right to monitor and review the content of all messages sent to or from this 
e-mail
address. Messages sent to or from this e-mail address may be stored on the
Infosys e-mail system.
***INFOSYS******** End of Disclaimer ********INFOSYS***
------------------------------------------------------------------------------
"Accelerate Dev Cycles with Automated Cross-Browser Testing - For FREE
Instantly run your Selenium tests across 300+ browser/OS combos.  Get 
unparalleled scalability from the best Selenium testing platform available.
Simple to use. Nothing to install. Get started now for free."
http://p.sf.net/sfu/SauceLabs
_______________________________________________
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions

iText(R) is a registered trademark of 1T3XT BVBA.
Many questions posted to this list can (and will) be answered with a reference 
to the iText book: http://www.itextpdf.com/book/
Please check the keywords list before you ask for examples: 
http://itextpdf.com/themes/keywords.php

Reply via email to