Table of Contents

Class FdfWriter

Namespace
iTextSharp.text.pdf
Assembly
iTextSharp.LGPLv2.Core.dll

Writes an FDF form. @author Paulo Soares (psoares@consiste.pt)

public class FdfWriter
Inheritance
FdfWriter
Inherited Members

Constructors

FdfWriter()

public FdfWriter()

Properties

File

Gets the PDF file name associated with the FDF.

public string File { get; set; }

Property Value

string

the PDF file name associated with the FDF

Methods

GetField(string)

Gets the field value.

public string GetField(string field)

Parameters

field string

the field name

Returns

string

the field value or null if not found

GetFields()

Gets all the fields. The map is keyed by the fully qualified field name and the values are PdfObject .

public INullValueDictionary<string, object> GetFields()

Returns

INullValueDictionary<string, object>

a map with all the fields

RemoveField(string)

Removes the field value. false otherwise

public bool RemoveField(string field)

Parameters

field string

the field name

Returns

bool

true if the field was found and removed,

SetFieldAsAction(string, PdfAction)

Sets the field value as a PDFAction . For example, this method allows setting a form submit button action using {@link PdfAction#createSubmitForm(String, Object[], int)}. This method creates an A entry for the specified field in the underlying FDF file. Method contributed by Philippe Laflamme (plaflamme) false if the name is incompatible with an existing field @since 2.1.5

public bool SetFieldAsAction(string field, PdfAction action)

Parameters

field string

the fully qualified field name

action PdfAction

the field's action

Returns

bool

true if the value was inserted,

SetFieldAsName(string, string)

Sets the field value as a name. false if the name is incompatible with an existing field

public bool SetFieldAsName(string field, string value)

Parameters

field string

the fully qualified field name

value string

the value

Returns

bool

true if the value was inserted,

SetFieldAsString(string, string)

Sets the field value as a string. false if the name is incompatible with an existing field

public bool SetFieldAsString(string field, string value)

Parameters

field string

the fully qualified field name

value string

the value

Returns

bool

true if the value was inserted,

SetFields(AcroFields)

Sets all the fields from this AcroFields

public void SetFields(AcroFields af)

Parameters

af AcroFields

the AcroFields

SetFields(FdfReader)

Sets all the fields from this FdfReader

public void SetFields(FdfReader fdf)

Parameters

fdf FdfReader

the FdfReader

SetFields(PdfReader)

Sets all the fields from this PdfReader

public void SetFields(PdfReader pdf)

Parameters

pdf PdfReader

the PdfReader

WriteTo(Stream)

Writes the content to a stream. @throws DocumentException on error @throws IOException on error

public void WriteTo(Stream os)

Parameters

os Stream

the stream