Skip to main content
October 2, 2015
Answered

Add multiple items to a drop down box

  • October 2, 2015
  • 7 replies
  • 44242 views

Hi all

Using Adobe Acrobat Pro DC Version 2015.008

I have just started preparing a fill in form. This will be my first one. I need to add a drop down box for selecting customers. The person filling in the form would click on the field and it would show them a list of customers. There are around 100 customers. Ideally they should be able to start typing in some letters and drop down.

Is it possible to add all customers at once to the drop down box? I can only see to add one at a time.

Any assistance with this would be greatly appreciated.

Regards

Vera Hawkins

This topic has been closed for replies.
Correct answer George_Johnson

You download and use the following demo PDF to speed up the process: http://acroscript.net/pdf/demos/comboPopulateTest.pdf

The idea is that you copy & paste or manually enter a list of items (each line is a separate item) into the large yellow multiline field, press the "Populate combo box" button, and then copy & paste the drop down field to your form. You'd then resize the field and set the other field properties to suit. Post again if you need help with it.

If you think you'll need to do this a lot, I've developed a utility that acts like a plug-in to Acrobat that makes this process much simpler and faster than the native Acrobat interface. You can send me a message through the forum for more info.

7 replies

sjkozak1
Participant
February 2, 2021

This saved me SO much time. Was so surprised to see a solution crafted for this particular request. Cannot thank you ENOUGH! 

Participant
June 5, 2020

Hello George, after searching countless sites, you have already produced what I was looking for. The project I was working on required a combo box to populated by quite a few list items and populating it manually in InDesign and/or Acrobat DC was time consuming. Thanks!  I am interested in how you built this. What kind of coding was implemented? Just curious.

Thom Parker
Community Expert
Community Expert
June 7, 2020

Download this demo and look at the code:

https://www.pdfscripting.com/public/FreeStuff/PDFSamples/PDFS_CopyPastListEntries.pdf

 

You can find out everything you ever wanted to know about PDF list programming here:

https://www.pdfscripting.com/public/List-Field-Usage-and-Handling.cfm

 

Thom Parker - Software Developer at PDFScriptingUse the Acrobat JavaScript Reference early and often
Participant
October 8, 2021

I found this utility and it is really cool.  Problem is I have a form which requires custom export values to be added to the dropdown.  I have looked to find a way to modify the script from above to do it and have been unable.

 

Also How would I do it the other way around?  Create the ListEntries field from the Dropdown1

So my user can I can edit thrm and them to update the dropdown?

It would also need to take the export values to the list so both can be updated.

Participant
April 17, 2020

I got the script, pasted in the list, hit populate combo box then copied it into my form in a new drop down box.  It only copies the first line.  Help

Thom Parker
Community Expert
Community Expert
April 17, 2020
Thom Parker - Software Developer at PDFScriptingUse the Acrobat JavaScript Reference early and often
Participant
September 13, 2017

To expand on this, is it possible to also define export values for each of the choices?   I will be creating a drop down with somewhere around 500 choices and they each have a corresponding lookup code that will need to be used when exported.

Inspiring
September 13, 2017

It's possible and easiest to do with the utility I mentioned earlier.

Known Participant
June 6, 2017

Excellent, you really solved my problem, it makes life so much easier.
Thank you very much for the help.

Regards,

Berg

try67
Community Expert
Community Expert
October 2, 2015

You can't do it directly, but if you have the list in a spreadsheet, or even a Word file, then it can be imported into the drop-down field using a script, like this one I've developed: Custom-made Adobe Scripts: Acrobat -- Import Items from a Text File to a Combo-Box or List Field

October 6, 2015

Thanks for the help. I will check out the script. Thought not sure how to run it. Ha Ha!!

George_JohnsonCorrect answer
Inspiring
October 2, 2015

You download and use the following demo PDF to speed up the process: http://acroscript.net/pdf/demos/comboPopulateTest.pdf

The idea is that you copy & paste or manually enter a list of items (each line is a separate item) into the large yellow multiline field, press the "Populate combo box" button, and then copy & paste the drop down field to your form. You'd then resize the field and set the other field properties to suit. Post again if you need help with it.

If you think you'll need to do this a lot, I've developed a utility that acts like a plug-in to Acrobat that makes this process much simpler and faster than the native Acrobat interface. You can send me a message through the forum for more info.

October 7, 2015

Thanks for that. I tried it but could not copy the filled box. It opens in acroscript.net and runs okay but I find it very hard to select the combo box. I did it once but had to update it and now it will only paste what I previously copied. Tried selecting it but it still does not copy.

Inspiring
October 7, 2015

You need to download the PDF and open it directly in Acrobat. Once you've pasted the list items in the large multiline field and press the "Populate combo box" button, you can go into form edting mode (Tools > Prepare Form) and copy the dropdown (combo box). You should then be able to switch to your form and paste the dropdown into your form.