TX Text Control provides all of the parts and processes needed to implement electronic (digital) signatures on PDF documents. From the dynamic creation of templates with signature fields, to the collection of signatures from end users, to the digital signing of PDF documents.
Creating Signature Lines in MS Word
The TX Text Control Signature
╰ TXTextControl Namespace
╰ SignatureField Class
An instance of the SignatureField class represents a signature field in a Text Control document. objects are compatible with the SignatureLine element in MS Word. To create a document in MS Word that contains a signature line, use the Signature Line button in the Text ribbon group of the Insert ribbon tab.
Additional information can be added to the signature line in the opened dialog.
The created signature line will look like the one shown in the following screenshot.
Adding Additional Information
When signing PDF documents, TX Text Control provides additional Signer
╰ TXTextControl Namespace
╰ SignerData Class
An instance of the SignerData class represents the data of a suggested signer connected with a SignatureField. properties for PDF compatibility.
|Address||Gets the address of a suggested signer.|
|ContactInfo||Gets contact information of a suggested signer, such as a phone number.|
|Name||Gets the name of a suggested signer.|
|Reason||Gets a reason why the document is signed.|
|Title||Gets the title of a suggested signer.|
The following code shows how to load the Office Open XML MS Word document and add additional properties to the SignerData.
Acquiring the Signature
The Document Viewer is used to capture the user's electronic signature. The following code combines the setting of additional signer data and adds the signature fields to the active signature fields of the Document Viewer. In order to make the code readable for this article, everything will be placed in Razor code.
The included signature field is converted into a signature box for the user to sign the document.
Signing Signature Fields
After the user has signed the document, the electronic signature is attached to the document and forwarded to the specified URL, along with the signature data, such as the signature image and the time stamp information.
Capturing electronic signatures and signing signature fields with certificates is a common feature of the TX Text Control Document Viewer. The most common server-side Web API methods for handling electronic signatures are described in this article.
The following HttpPost method loads the signed document and applies a certificate to each of the signature fields by going through the Signature
╰ Web.MVC.DocumentViewer Namespace
╰ SignatureBox Class
The SignatureBox class represents the shown signature box in the UI. in a loop.
All signature fields are digitally signed as a result of this implementation. The following screenshot shows the PDF file as it opens in Adobe Acrobat Reader and shows the valid signature field with the properties of the custom signer data. The created version of the document carries a digital signature that verifies that no tampering occurred after the document was created.