eSign document with Form Field signature

What is a Form Field?

form field is the interactive element located on document page that allows user data input through various control types like free input text box, multi-line text box, check boxes, drop down lists etc. Different document types support specific list of form field types. These elements are used to collect information from user on template form. Each Form Field element has an unique name, settings and value field. Form Fields should have unique names within the form. Picture below demonstrates possible document page with form fields.

How to eSign document with Form Field signature

GroupDocs.Signature for Java supports creation of new form fields or update existing ones within the documents. Class FormFieldSignOptions specifies different options for Form Field signature. 
The FormFieldSignOptions  class contains one FormFieldSignature object to put to the document.
Here are the list of different Form Field signature classes that could be set to FormFieldSignOptions 

Here are the steps to add Form Field signatures into document with GroupDocs.Signature:

NOTE: At the moment GroupDocs.Signature supports creation of Form Field signatures for PDF documents only.

This example shows how to sign PDF document with Form Field electronic signature on document page. 

Signature signature = new Signature("sample.pdf");

// instantiate text form field signature
FormFieldSignature textSignature = new TextFormFieldSignature("FieldText", "Value1");
// instantiate options based on text form field signature
FormFieldSignOptions options = new FormFieldSignOptions(textSignature);

options.setHorizontalAlignment(HorizontalAlignment.Left);
options.setVerticalAlignment(VerticalAlignment.Top);
options.setMargin(new Padding(10, 20, 0, 0));
options.setHeight(10);
options.setWidth(100);

// sign document to file
signature.sign("signed.pdf", options);

More resources

Advanced Usage Topics

To learn more about document eSign features, please refer to the advanced usage section.

GitHub Examples 

You may easily run the code above and see the feature in action in our GitHub examples:

Free Online App 

Along with full-featured .NET library we provide simple, but powerful free Apps.
You are welcome to eSign PDF, Word, Excel, PowerPoint documents with free to use online GroupDocs Signature App.

© Aspose Pty Ltd 2001-2022. All Rights Reserved.