Gnostice PDFOne
Pro. Ed. v5.0.0


com.gnostice.pdfone
Interface PdfFormFieldRenameHandler


public interface PdfFormFieldRenameHandler

This interface defines an run-time event generated by method PdfDocument.write() (in reading mode) when a form field is saved to the document. This event can be particularly useful when using methods such as

If it is likely that more than one form field in the combined document will have the same name, only one of those form fields may be displayed* by viewer applications. To prevent this, user classes can implement this interface and use the onRenameField event to provide different names for such same-name form fields. Viewer applications will then display these form fields.

NOTE: As of v2.0, this event is available only in "reading mode." In future, this event may be available in "creation mode" also. (See PdfDocument class.)

* - Multiple form fields that have the same name will be displayed if PdfDocument.setOverrideFieldAppearanceStreams(true) is used. However, these form fields will hold the same value. Changing the value in one will automatically update the others.


Method Summary
 void onRenameField(PdfDocument d, String oldName, StringBuffer newName, boolean[] rename)
          Called by PdfDocument.write() when it tries to save a form field.
 

Method Detail

onRenameField

public void onRenameField(PdfDocument d,
                          String oldName,
                          StringBuffer newName,
                          boolean[] rename)
Called by PdfDocument.write() when it tries to save a form field. User classes implementing this interface can handle this event to provide a new name for the form field specified by oldName.

Parameters:
d - document which is being saved
oldName - existing name of the form field
newName - new name of the form field
rename - whether to rename the form field

Gnostice PDFOne
Pro. Ed. v5.0.0

To contact our support team, send an e-mail to support@gnostice.com.
 
© 2010 Gnostice Information Technologies Private Limited. All rights reserved.
www.gnostice.com