We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Convert from Word to PDF with Form Fields

We have developed a system using Aspose.Word to generate a large Word document by concatenating 60 one page Word docs. This all works well.



Now we want to convert this large Word doc to PDF. Easy enough. But additionally we want to somehow embed markers in the Word doc that become PDF Form Fields when converted to PDF. The Form Fields will only be text fields.



Does anyone have any suggestions?

Hello!<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

Thank you for your inquiry.

This can be done with Aspose.Words. If you’d like to have text form fields in resulting PDF then it is better to insert their MS Word counterparts in the source document.

Here is special method Aspose.Words.DocumentBuilder.InsertTextInput:

http://www.aspose.com/documentation/file-format-components/aspose.words-for-.net-and-java/aspose.words.documentbuilder.inserttextinput.html

Of course you should know where to insert them and properly position the DocumentBuilder instance before you insert. You can place bookmarks in that places and use Aspose.Words.DocumentBuilder.MoveToBookmark:

http://www.aspose.com/documentation/file-format-components/aspose.words-for-.net-and-java/aspose.words.documentbuilder.movetobookmark_overloads.html

Then, it is important, set Aspose.Words.SaveOptions.PdfExportFormFieldsAsText to false:

http://www.aspose.com/documentation/file-format-components/aspose.words-for-.net-and-java/aspose.words.saveoptions.pdfexportformfieldsastext.html

Please let us know whether you got to a solution.

Regards,

Great - I’ll download Aspose.PDF and give it a try. I’ll let you know how it goes…