Articles in this section
Category / Section

How to add digital sigature in exsiting signature field in the document?

1 min read

How to add digital signature in existing signature field in the document:

It is possible to add digitally sign in an existing signature field. For this you need to pass the signature field information and certificate details in PdfSignature class. Below is the code snippet.

C#:

 
//Loads the Certificate
PdfCertificate pdfCert = new PdfCertificate(@"../../Data/PDF.pfx", "syncfusion");
 
//Load an existing Pdf document
PdfLoadedDocument doc = new PdfLoadedDocument("../../Data/emptypdf_modified.pdf");
 
//Get the signature field to be digitally signed
PdfLoadedSignatureField f = doc.Form.Fields["Firma1"] as PdfLoadedSignatureField;
 
// Pass the signature field and certificate information in PdfSignature class, this  will digitally sign the existing signature field
PdfSignature signature = new  PdfSignature(doc, f.Page, pdfCert, f.Name, f);
 
//Save the document and dispose it.
doc.Save("signed1.pdf");
doc.Close(true);
 
 

 

Sample Link:

http://www.syncfusion.com/downloads/support/directtrac/141714/ze/SignSIgnatureField445227762

 

Did you find this information helpful?
Yes
No
Help us improve this page
Please provide feedback or comments
Comments (0)
Please sign in to leave a comment
Access denied
Access denied