Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Rotate text field?

Participant ,
Feb 20, 2017 Feb 20, 2017

I have a row of text fields that need to be rotated based on another field value.

From this:

Screen Shot 2017-02-20 at 10.59.35.png

To this:

Screen Shot 2.png

I've read through the forum and the only option I can see is to resize each text box? But that would be a lot of coordinates to script!
Cheers in advance

(P.S. Each text field has a custom calculation script and are individually hidden/shown based on another fields value, so they need to be text fields as far as I can see as opposed to image/button fields!)

TOPICS
Acrobat SDK and JavaScript
3.7K
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Community Expert , Feb 20, 2017 Feb 20, 2017

This is almost perfect timing... I've had a blog post in the works about rotating form fields for a while, and I took your question as the prompt to publish it. Take a look here for a JavaScript solution to rotate PDF form fields: Rotate PDF Fields in Adobe Acrobat Using JavaScript - KHKonsulting LLC

Translate
Community Expert ,
Feb 20, 2017 Feb 20, 2017

Yes, you will need to calculate the new rect value for your fields, and also set their rotate property (but that only affects the direction of the text in the field, so you can't do only that).

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Feb 20, 2017 Feb 20, 2017

This is almost perfect timing... I've had a blog post in the works about rotating form fields for a while, and I took your question as the prompt to publish it. Take a look here for a JavaScript solution to rotate PDF form fields: Rotate PDF Fields in Adobe Acrobat Using JavaScript - KHKonsulting LLC

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Participant ,
Feb 21, 2017 Feb 21, 2017
LATEST

Thanks Heinz, I checked your script and it works fine.
Your blog also suggest that I can do an array of fields so I will work on that.

Kind regards

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines