Thank you Asad Ali!
I’ve attached fully executable code which demonstrates the difference between: digitally signing normal PDF file and a rotated PDF file. The question is with respect to the location and the way signature is being printed on PDF file. I’ve provided 3 sample PDF files, one is normal, one is rotated by 90 degree angle and one is rotated by 270 degree angle. Please sign all three documents and see the output PDF file. Even through Ive kept the location of the signature same, the signature is getting printed at different locations and also signature is flipped. My requirement is: even though document is rotated by any angle, the signature should be printed at the same location without flipping.
Note: Attached file is SignRotatedPDF.zip. Upon unzipping there are sample input PDF files and a source code. Before executing the code, please provide your digital certificate (.pfx) path with password at line number 58 and 60 in Form1.cs file.
Because of upload file size limitation, I’ve removed Aspose.PDF.dll (version 126.96.36.199) from project reference. Please add reference of this library to the project.
SignRotatedPDF.zip (512.6 KB)
Also I’ve provided sample output PDF files in “sample_output” folder of the project directory which are digitally signed documents. These output PDF files are 1. Normal(No Rotation) 2. Rotated by 90 degree 3. Rotated by 270 degree. These sample output files are for your reference to see how the signatures are printed.
Steps to execute:-
- Launch project and executable
- Browse desired input file
- Click on “SIgn PDF” button
- Open Output PDF file to see the output.
Please let me know if you face any issues in executing this project.