1 Reply Latest reply on Dec 7, 2015 7:02 PM by George_Johnson

    Can not get ComboBox export value to work correctly.

    Jim MacD


      Can not get ComboBox export value to work correctly. When an item is selected from the ComboBox, the export value is the previously selected export value for an item.


      ComboBox "CLIENT-DIRECTION-Relinquishing-Institution-Name" has the following items with export values.

      Field export value is being moved to "CLIENT-DIRECTION-Relinquishing-Institution-Name-Hidden"



      Item 0 ---> " " (blank space)


      Item 1 ---> AGF-AGF Investments Inc. (as agent for B2B Trustco)

      Export value --> AGF Group of Funds


      Item 2 ---> DYN-1832 Asset Management L.P., AS AGENT FOR THE BANK OF NOVA SCOTIA TRUST COMPANY

      Export value ---> Dynamic Funds


      Item 3 ---> MFC-Mackenzie Financial Corporation (as agent for B2B Trustco)

      Export value ---> Mackenzie Investments


      If the items are selected as follows: Item 1 will export " ", Item 2 will export "AGF Group of Funds", Item 3 will export "Dynamic Funds". It's always the previously selected export value.


      Code used within ComboBox:


                  if(event.value != " ")




                              this.getField("CLIENT-DIRECTION-Relinquishing-Institution-Name-Hidden").value = this.getField("CLIENT-DIRECTION-Relinquishing-Institution-Name").value;








        • 1. Re: Can not get ComboBox export value to work correctly.
          George_Johnson MVP & Adobe Community Professional

          You didn't say where you placed the code. With a combo box, it could be in the keystoke, format, validate, calculate, on blur, etc. What you should do is use something like the following as the field's custom Keystroke script:


          // Custom Keystroke script for combo box

          (function () {


              if (!event.willCommit) {

                  if (event.changeEx !== " ") {

                      getField("CLIENT-DIRECTION-Relinquishing-Institution-Name-Hidden").value = event.changeEx;







          Be sure to set the "Commit selected value immediately" property. More information on the event model and properties is in the Acrobat JavaScript reference.