Fillable PDF Text field type Date and type Calculate not working correctly

I am creating a Fillable PDF from an RTF document using the Word fields for Text boxes and saving as a Fillable PDF. It is mostly working except for a couple of things.

A text box with type Date lets the user type anything in.

A text box with type Calculate has the correct value when opened, but if the calculation involves other fillable fields, the formula does not update the field in the PDF.

Are these types supported for Aspose.Words saving a document as PDF?

The third problem is one of text box size. If there is no default value in the text box the size defaults to 4 characters wide. If you have a default for the field the size is enough to fit the default text. Is there some way to size the fields when Aspose.Words saves a document as PDF? Maybe a way to set the default?

Thanks.

Hi Scott,


Thanks for your inquiry. Please attach your input Word document and output Pdf file showing the undesired behavior here for testing. Also, please share the source code you’re using on your end to generate Pdf files. We will investigate the issues on our end and provide you more information.

Best regards,

I have attached the original document, the PDF, and the program I used to convert it. It is a simple command line program that takes the input file name, output file name, and type to save as.



The first two text boxes are empty and with a default. Near the bottom is a text box set as type Number with the initial value of 123, a text box of type Date that is empty, a text box of type Current Date, a text box of type Current Time and finally a text box of type Calculation. It simply adds 20 to the value in the Number text box.



The text box of type Date will let you type in anything.



The text box of type Calculation does not update when you change the value in the Number text box, even if you save and re-open it.



The top two text boxes were simply experimenting with the initial size of a text box, I was trying to figure out a way to set the initial size with properties in Word.

Hi Scott,


Thanks for the details. We are working over your query and will get back to you soon.

Best regards,

Hi Scott,


Thanks for being patient. You can simulate increase in initial size of text box by using the following code:
Document doc = new Document(getMyDir() + “PDF Fillable_V1.rtf”);

for(FormField field : (Iterable<FormField>) doc.getRange().getFormFields()){
if (field.getName().equals(“Text1”)){
field.setResult(" ");
}
}

PdfSaveOptions options = new PdfSaveOptions();
options.setPreserveFormFields(true);

doc.save(getMyDir() + “out.pdf”, options);

Secondly, while using the latest version of Aspose.Words i.e. 15.5.0, I managed to reproduce couple of issues on my side. I have logged the following issues in our bug tracking system.

WORDSNET-12031: A text box with type Date lets the user type anything in PDF
WORDSNET-12032: A text box with type Calculate does not update the field in the PDF

Your thread has also been linked to these issues and you will be notified as soon as they’re resolved. Sorry for the inconvenience.

Best regards,

Thanks for the suggestion and opening the cases. I have found 5 more issues with the fillable fields. I have attached a zip file with the original and the PDF for each of the issues.



1. Checkbox is not honoring the size if you click the checkbox for Exactly and then pick a size other than the current font size. My sample has one at auto and one at 20pt. In the RTF they look correct, in the PDF they are the same size.



2. Date Formats are not working. This is probably just an extension of the field not forcing a date in the first place. Any formats are not being enforced or used to format the data typed in.



3. DropDown lists are overlaying the text next to them on the right. It looks like the text is being placed without taking the size of the drop down in to consideration.



4. Frame placement during page wrap seems to be using the page end instead of the margin for deciding if a Frame should be pushed to the next page.



5. Numbers are not honoring formatting and look like they allow you to type in any characters instead of just digits.



I thought I would just keep all the PDF Fillable issues in this one thread.



Thanks.

Hi Scott,


Thanks for your inquiry. While using the latest version of Aspose.Words i.e. 15.5.0, I managed to reproduce and log the following issues.

1. WORDSNET-12046: Checkbox is not honoring the size in PDF

2. WORDSNET-12047: Date Formats are not working in generated PDF.
The ‘TextFormFieldType’ of the three form fields in your document are ‘Date’, ‘Regular’ and ‘Regular’ respectively. I have modified your document (see attached Date Format-modified.rtf) but still the problem exists as you describe it.

3. WORDSNET-12048: DropDown lists are overlaying the text next to them on the right in PDF

4. WORDSNET-12049: A Frame is rendering at the end of previous page in PDF

5. WORDSNET-12050: Number FormFields are not honoring Number Formatting in PDF

Your thread has also been linked to these issues and you will be notified as soon as they are resolved. Sorry for the inconvenience.

Best regards,

Hi Scott,


Regarding WORDSNET-12032, I am afraid, the implementation of the fix of this issue has been postponed till a later date. This is because currently ‘Calculate’ text-boxes are not exported to the PDF. This feature probably will not be implemented in the nearest future because it requires a significant effort. We apologize for any inconvenience.

Best regards,

Hi Scott,


Regarding WORDSNET-12032, our product team has completed the work on your issue and has come to a conclusion that they won’t be able to implement the fix to this issue. This issue (WORDSNET-12032) is now closed with ‘Won’t Fix’ resolution.

Best regards,

The issues you have found earlier (filed as WORDSNET-12046) have been fixed in this .NET update and this Java update.


This message was posted using Notification2Forum from Downloads module by aspose.notifier.

The issues you have found earlier (filed as WORDSNET-12049) have been fixed in this .NET update and this Java update.


This message was posted using Notification2Forum from Downloads module by aspose.notifier.