SignatureFields Property
- Namespace
TXTextControl
- Package
TXTextControl.asTextControl. WPF. SDK TXTextControl.from the private NuGet feed or Text Control Offline Packagesdll
Description
Specifies an array of DigitalSignature objects, each of which defines an X.509 certificate and is associated with a SignatureField in the document. These certificates can be used to digitally sign a PDF or a PDF/A file. For other formats this property has no meaning. To associate a certificate with a signature field a name must be specified for the field.
Syntax
public DigitalSignature[] SignatureFields { get; set; }Public Property SignatureFields As DigitalSignature()Examples
The following example signs a named PDF signature field with an X.509 certificate supplied by secure certificate-loading code.
SignatureField approval = new(new System.Drawing.Size(3000, 1000), "ApproverSignature", 10);
textControl.SignatureFields.Add(approval, FrameInsertionMode.AsCharacter);
DigitalSignature fieldSignature = new(certificate, null, "ApproverSignature");
SaveSettings saveSettings = new()
{
SignatureFields = new[] { fieldSignature }
};
textControl.Save("signed-approval.pdf", StreamType.AdobePDF, saveSettings);Dim approval As New SignatureField(New System.Drawing.Size(3000, 1000), "ApproverSignature", 10)
textControl.SignatureFields.Add(approval, FrameInsertionMode.AsCharacter)
Dim fieldSignature As New DigitalSignature(certificate, Nothing, "ApproverSignature")
Dim saveSettings As New SaveSettings() With {
.SignatureFields = New DigitalSignature() { fieldSignature }
}
textControl.Save("signed-approval.pdf", StreamType.AdobePDF, saveSettings)