简体   繁体   中英

Adobe Acrobat - populate a drop down or list with selections from another

I'm working on a corm in Adobe and am wondering if there is a way to auto-populate a list or drop-down with the selections from two other drop-downs. Example: Drop Down 1 (select 1): red, orange, yellow, green, blue, indigo, violet and Drop Down 2 (select 1): red, orange, yellow, green, blue, indigo, violet. I need to create a 3rd drop-down (or a list would also work) with the selections from Drop Down 1 & 2 (ie if Red & Violet were chosen the options for the 3rd Drop Down or List would automatically show up as Red or Violet. Is there a script to accomplish this?

That's actually pretty easy. In the MouseUp Action for DropDown1 and DropDown1, add a JavaScript that set the items for DropDown3. Something like this...

this.getField("DropDown3").setItems([this.getField("DropDown1").value, this.getField("DropDown2")]).value;

You'd use the same code if DropDown3 were a list.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM