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

If/then Command to delete and change positions of text boxes if null

New Here ,
Dec 16, 2019 Dec 16, 2019

Copy link to clipboard

Copied

Hello!

 

I am trying to make a business card form for employees to fill out.  For the phone number portion there are a lot of options. Some employees have an office phone, office phone with an exstension, mobile number, and/or a fax line. 

 

My goal is to have it so that if a text box for a fax or mobile is left blank the text box(es) is deleted. Additionally, if an emlpoyee only has a mobile or a fax (I know it is almost 2020; who still uses fax?!) that the office phone box is deleted and all other textboxes' position is shifted up to keep with the formatting of the document. 

 

Any help would be greatly appreciated! 🙂

TOPICS
Acrobat SDK and JavaScript

Views

208

Translate

Translate

Report

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
LEGEND ,
Dec 16, 2019 Dec 16, 2019

Copy link to clipboard

Copied

While it's not completely impossible to move text boxes around, it's pretty tiresome. I suggest instead you just think in terms of the card being a series of lines, and fill them as you need to. Really, though, such a flexible layout is better done in Word.

Votes

Translate

Translate

Report

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
New Here ,
Dec 16, 2019 Dec 16, 2019

Copy link to clipboard

Copied

Thanks for the feedback, but this needs to be completed as a form in Adobe Acrobat

Votes

Translate

Translate

Report

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 ,
Dec 16, 2019 Dec 16, 2019

Copy link to clipboard

Copied

LATEST

Here's an article that explains page coordinates and positioning fields:

https://www.pdfscripting.com/public/PDF-Page-Coordinates.cfm?sd=40

 

You'll find two sample PDFs here that demonstrate creating new fields and moving them about on the page.

They're called "Bouncing Button" and "Swat the Fly":

https://www.pdfscripting.com/public/Free-Sample-PDF-Files-with-scripts.cfm

Thom Parker - Software Developer at PDFScripting
Use the Acrobat JavaScript Reference early and often

Votes

Translate

Translate

Report

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