I am using the following line of code to open a "secured" pdf file:
Aspose.Pdf.Document pdfDocumentSource = new Aspose.Pdf.Document(fileToCombine);Aspose.Pdf.Document pdfDocumentSource = new Aspose.Pdf.Document(fileToCombine);
This results in the following error:
System.NotSupportedException was caught
Message=Specified method is not supported.
Source=Aspose.Pdf
StackTrace:
at . ..ctor( , Byte[] , Int32 , String )
at . . ()
at . ..ctor( , )
at . . ( , )
at . . ()
at . . ( , )
at . . . ( , & )
at . . ( , & )
at . . (Int64 , ArrayList )
at . . ()
at . ..ctor(Stream , String , Boolean )
at . ..ctor(String )
at . . (String )
at . ..ctor(String )
at . . (String )
at . . (String )
at . ..ctor(String )
at Aspose.Pdf.Document. (String , String )
at Aspose.Pdf.Document..ctor(String filename)
at PDFCombine.PDFCombine.appendPDFFileToPDFDocument(String fileToCombine, Document document) in c:\Work\Personal\Jason\Projects\Test\PDFCombine\PDFCombine\PDFCombine.cs:line 293
at PDFCombine.PDFCombine.combinePDFWithAssociatedFiles(String pdfFilePath) in c:\Work\Personal\Jason\Projects\Test\PDFCombine\PDFCombine\PDFCombine.cs:line 115
InnerException: System.NotSupportedException was caught
Message=Specified method is not supported.
Source=Aspose.Pdf
StackTrace:
at . ..ctor( , Byte[] , Int32 , String )
at . . ()
at . ..ctor( , )
at . . ( , )
at . . ()
at . . ( , )
at . . . ( , & )
at . . ( , & )
at . . (Int64 , ArrayList )
at . . ()
at . ..ctor(Stream , String , Boolean )
at . ..ctor(String )
at . . (String )
at . ..ctor(String )
at . . (String )
at . . (String )
at . ..ctor(String )
at Aspose.Pdf.Document. (String , String )
at Aspose.Pdf.Document..ctor(String filename)
at PDFCombine.PDFCombine.appendPDFFileToPDFDocument(String fileToCombine, Document document) in c:\Work\Personal\Jason\Projects\Test\PDFCombine\PDFCombine\PDFCombine.cs:line 293
at PDFCombine.PDFCombine.combinePDFWithAssociatedFiles(String pdfFilePath) in c:\Work\Personal\Jason\Projects\Test\PDFCombine\PDFCombine\PDFCombine.cs:line 115
InnerException:
Is this the intended behavior or is this a bug? Is there any way I can detect whether a PDF document is "secured" before trying to open it?
I have attached the pdf document.