pdfbox-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Krishnendu Datta <datta.kr...@gmail.com>
Subject Re: Pdfbox PDDocument.gwtAccessPermission().canPrint() not working as expected. Please help...
Date Sat, 09 Nov 2013 21:22:29 GMT
Hi All,

I am using pdfbox for validating a pdf document and one of the validation
states that whether the pdf document is printable or not.

I use the following code to perform this operation:

PDDocument document = PDDocument.load("<path_to_pdf_file>");
System.out.println(document.getCurrentAccessPermission().canPrint());

but this is returning me *true *though the pdf when opened shows the print
icon disabled.

The file that is tested with can be found at :

https://drive.google.com/file/d/0B-Ouc3yLq4_mTzVraW5Nd0ZBUzg/edit?usp=sharingt?usp=sharing

Any help regarding this will be appreciated.

Thanks,
Krishnendu


On Sun, Nov 10, 2013 at 1:53 AM, Gilad Denneboom
<gilad.denneboom@gmail.com>wrote:

> You can't attach files to emails to this list. Upload them to a
> file-sharing website and post the link, instead.
>
>
> On Sat, Nov 9, 2013 at 8:17 PM, Krishnendu Datta <datta.krish@gmail.com
> >wrote:
>
> > Hi All,
> >
> > I am using pdfbox for validating a pdf document and one of the validation
> > states that whether the pdf document is printable or not.
> >
> > I use the following code to perform this operation:
> >
> > PDDocument document = PDDocument.load("<path_to_pdf_file>");
> > System.out.println(document.getCurrentAccessPermission().canPrint());
> >
> > but this is returning me *true *though the pdf when opened shows the
> > print icon disabled.
> >
> > Attaching the sample pdf which I used for testing.
> >
> > Any help regarding this will be appreciated.
> >
> > --
> > Thanks and Regards,
> > Krishnendu
> >
> >
>



-- 
Thanks and Regards,
Krishnendu Datta
Assistant Consultant(Technical Architect)
Tata Consultancy Services(TCS)
Mobile: +91-9163117896

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message