Chapter 8: Filling out interactive forms

Chapter 8 of the book iText in Action 2E covers:
  • Creating AcroForms using iText
  • Manipulating AcroForm fields
  • Manipulating XFA forms
  • Filling out Reader-enabled forms
In this chapter, you'll explore the two types of interactive forms that are supported in the PDF specification. One of these technologies uses PDF objects to define a form. These forms are called AcroForms, and they can easily be created and manipulated using iText. The other type of forms uses the XML Forms Architecture (XFA). These come in two flavors: static XFA forms and dynamic XFA forms. Most of the static XFA forms can be filled with iText in the same way as AcroForms, using the same code, but there are exceptions. You can also use iText to inject an XML data file into a dynamic XFA form. Finally, you'll learn more about Reader-enabled forms. Filling such a form with iText can break the extra features that are added to the form, but you can avoid this if you follow the workarounds explained in the book.
  • 8.1: Introducing AcroForms
  • 8.2: Selecting states or trigger actions with button fields
    • 8.2.1: Radio fields and radio buttons
    • 8.2.2: Check boxes
    • 8.2.3: Pushbuttons
  • 8.3: Filling in data with text fields
    • 8.3.1: Creating text fields
    • 8.3.2: Filling out text fields
    • 8.3.3: Text fields and fonts
    • 8.3.4: Validating text fields
  • 8.4: Selecting options with choice fields
    • 8.4.1: Creating lists and combo boxes
    • 8.4.2: Manipulating lists and combo boxes
  • 8.5: Refining the form filling process
    • 8.5.1: Choosing field names
    • 8.5.2: Optimizing the filling process
    • 8.5.3: Partial form flattening
    • 8.5.4: Customized form flattening
  • 8.6: Introducing the XML Forms Architecture (XFA)
    • 8.6.1: Static XFA forms
    • 8.6.2: Dynamic XFA forms
  • 8.7: Preserving the usage rights of reader enabled forms
    • 8.7.1: Reader enabling a form using Adobe Acrobat
    • 8.7.2: Filling out Reader enabled forms using iText
  • 8.8: Summary
Consult the full table of contents, take a look at the illustrations from this chapter, or try out some of the examples: