Free Support Forum - aspose.com

Concatenating a PDF that is password protected

I am concatenating a number of Equipment Description PDF files from various vendors. Some of these vendors distribute their documentation PDF’s with password protection. When using the PdfFileEditor.Concatenate(inStream(),outStream) method I get no errors. When viewing the file after creation, however, the pages that have been added have place holders and when you access each of the password protected pages a blank shows up and an error pops up stating “There was an error processing a page. Invalid function resource.“

You can click the OK button and navigate to the next page which will either display, or if it was a password protected page will display the same error.

Is there a way to discover that the PDF is protected before adding it?

DonD
<a target=”_blank” title=“mailtoBig Smiledeveux@rengeek.com” href=“mailtoBig Smiledeveux@rengeek.com”>ddeveux@rengeek.com

Dear DonD,

Thanks for considering Aspose.

Checking whether the Pdf file was protected before processing is not supported by the kit now, but I think it can be added as a new feature in next release, the newest will may be released at the end of the month.

Hi,

The kit1.3 is released, you can use PdfFileInfo to check whether the Pdf file is protected before concatenating these Pdf files.