Copy link to clipboard
Copied
Using Acrobat Pro I created a fillable PDF form for my clients who copy and paste a large amount of information. Because they are using Acrobat Reader, I have designated text field properties with desired font and size, multi-line, check spelling, etc...and enabled "rich text formatting" so that they can manipulate their "raw" text as needed to be bold, italic, underlined, etc. However, when my client attempts to copy/paste source text into the desired form field, the information is retaining "source" formatting rather than what is already designated in the field properties. (Even occurs when source text is .txt - raw 'unformatted text'.)
Yes, I get that this is relates to the designation of "Rich Text Formatting." Does anyone have a Custom Format Script to use to circumvent the issue?
Thanks in advance!
Copy link to clipboard
Copied
See the example on Page 658 of the Adobe Acrobat SDK JavaScript API, JavaScript™ for Acrobat® API Reference -- "Span properties"
It explains how to use Span properties to pass rich text to a rich text field.
Copy link to clipboard
Copied
See the example on Page 658 of the Adobe Acrobat SDK JavaScript API, JavaScript™ for Acrobat® API Reference -- "Span properties"
It explains how to use Span properties to pass rich text to a rich text field.
Copy link to clipboard
Copied
Great info! I need the exact same functionality but the link isn't working anymore. This looks like the right place:
https://opensource.adobe.com/dc-acrobat-sdk-docs/library/jsapiref/JS_API_AcroJS.html#span
Thanks so much. I'll need help applying the script to my situation as I'm a novice a JS, but I'll find that somewhere.
Copy link to clipboard
Copied
Thanks for updating this old thread.
Therw are still some old links on the Internet that you may download the older Acrobat JavaScript API reference guide in PDF format.
Would you mind explaining in more detail what do you need help with?
Also, are you currently using a script ? If yes, do you mind sharing it?
Copy link to clipboard
Copied
Hi! and thanks for the reply.
No I'm not currently using a script. I have no experience with custom scripts in Acrobat, I just know that it's possible.
Our situation is that a client wants to copy text into a form field and retain the custom font, size, color. They need the number of characters to be flexible and the font needs to get smaller if needed when the message is longer. We're talking about 3-4 lines in a multi-line text field. We are assuming that the client has Reader not Acrobat Pro.
Copy link to clipboard
Copied
Update: Adobe tech support just told me I have to have Acrobat API or SDK to use javascripts. Acrobat Pro that comes with CC is not enough.
Copy link to clipboard
Copied
This info is not correct!
Copy link to clipboard
Copied
That is not a surprise (that this info is incorrect).
Copy link to clipboard
Copied
Hello, what do you mean with CC ?
I'm having the same issue, trying to fill text fields with text with styles, using Java, and writting XML for example. But it seems it doesn't work.
Copy link to clipboard
Copied
I cannot open this page
Copy link to clipboard
Copied
Copy link to clipboard
Copied
In practice, what does this mean, is a new package needed in Java ? Or how could I write richtext in Java into these fields?
Copy link to clipboard
Copied
Acrobat uses Javascript, not Java.

