[Solved] PDF - SignExistingField

1 Answer 28 Views
Documentation
Alexandre
Top achievements
Rank 1
Alexandre asked on 14 Aug 2026, 03:37 PM

Hello,

I'm signing a PDF field with a signature using the "SignExistingField" that exists in the PdfStreamSigner (Telerik version 2026.2.520.462)

I can see the signature in the field but the signature properties that i set ex: Reason, will show allways empty.

Thanks

1 Answer, 1 is accepted

Sort by
0
Yoan
Telerik team
answered on 18 Aug 2026, 12:23 PM

Hi Alexandre,

I created a sample project for signing a PDF document and setting signature properties like Reason and Location. I used the following sample implementation shown in the Getting Started with Digital Signature article:

int signatureFieldWidth = 200; int signatureFieldHeight = 50; int signaturePositionLeft = 10; int signaturePositionTop = 10; X509Certificate2 certificate = new X509Certificate2("..\\..\\..\\JohnDoe.pfx", "johndoe"); SignatureField pdfSignature = new SignatureField("SignatureField"); pdfSignature.Signature = new Signature(certificate);

pdfSignature.Signature.Properties.Reason = "I am the author of this document."; pdfSignature.Signature.Properties.Location = "My City, My Country"; Form pdfForm = new Form(); pdfForm.FormSource = new FormSource(); pdfForm.FormSource.Size = new Size(signatureFieldWidth, signatureFieldHeight); FixedContentEditor editor = new FixedContentEditor(pdfForm.FormSource); pdfForm.Position.Translate(signaturePositionLeft, signaturePositionTop); editor.DrawText($"{certificate.GetNameInfo(X509NameType.SimpleName, false)} {DateTime.Now.ToString("yyyy.MM.dd HH:mm")}"); SignatureWidget signatureWidget = pdfSignature.Widgets.AddWidget(); signatureWidget.Content.NormalContentSource = pdfForm.FormSource; signatureWidget.Rect = new Rect(signaturePositionLeft, signaturePositionTop, signatureFieldWidth, signatureFieldHeight); signatureWidget.RecalculateContent(); RadFixedDocument document = new RadFixedDocument(); RadFixedPage pdfPage = document.Pages.AddPage(); pdfPage.Annotations.Add(signatureWidget); FixedContentEditor pageEditor = new FixedContentEditor(pdfPage); pageEditor.Position.Translate(signaturePositionLeft, signaturePositionTop); pageEditor.DrawForm(pdfForm.FormSource); document.AcroForm.FormFields.Add(pdfSignature); signatureWidget.RecalculateContent(); string signedDocumentFilePath = "..\\..\\..\\signed.pdf"; File.Delete(signedDocumentFilePath); using (Stream output = new FileStream(signedDocumentFilePath, FileMode.OpenOrCreate, FileAccess.ReadWrite)) { new Telerik.Windows.Documents.Fixed.FormatProviders.Pdf.PdfFormatProvider().Export(document, output, TimeSpan.FromSeconds(10)); } var psi = new ProcessStartInfo() { FileName = signedDocumentFilePath, UseShellExecute = true }; Process.Start(psi);

On my end, examining the result file and signature in Adobe Acrobat, I am able to see the set properties:

I am attaching the project for your disposal. Feel free to examine it and compare implementations. Let me know if there is something different on your end that might affect the results you are seeing or if I'm missing something. If you can, please provide your implementation instead so I can test and investigate it.

NOTE: Please keep in mind that this is a public Q&A forum thread, so any resources shared here will be publicly accessible. Please avoid sharing confidential, sensitive, or personally identifiable information.

Regards,
Yoan
Progress Telerik

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.

Tags
Documentation
Asked by
Alexandre
Top achievements
Rank 1
Answers by
Yoan
Telerik team
Share this question
or