Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

How to make choices in a drop down box change a value in another box

skipenguin101
Level 1
Level 1

Hi,  I am fairly new to the world of creating forms in Adobe so please bear with my question if it seems simple.  I have seen where a lot of people are using code and I am very confused.  I am creating an order form and have created a drop down box (combo box).  There are 4 choices in this drop down box.  When the user chooses one of these choices, I would like an amount to appear in a seperate box.  Each choice would have a different amount.  Is this possible?  If so, could someone please give me step by step instructions.  I appreciate any help given!!

7 Replies
pguerett
Level 10
Level 10

Yes it is possible but not without writing some code. Lets assume that youe DropDown is called DDList and the field you want to update is called TextField1 and the values in the DD are A, B, C, D. The code woudl look something like this and woudl be placed on the exit event of the DDList:

if (this.rawValue == "A") {

     TextField1.rawValue = "Value 1"

} else {

      if (this.rawValue == "B"){

          TextField1.rawValue = "Value 2"

      } else {

           if (this.rawValue == "C"){

               TextField1.rawValue = "Value 3"

           } else {

               TextField1.rawValue = "Value 4"

          }

     }

}

skipenguin101
Level 1
Level 1

Ok, here is what I have but am not seeing anything happen.  Under the Combo box properties, actions tab, add an action- mouse exit, run a javascript

if (this.rawValue == "Bore") {Rate1.rawValue = "4.50"} else {if (this.rawValue == "Bore Railhead Adder"){Rate1.rawValue = "5.25"} else {if (this.rawValue == "Trench"){Rate1.rawValue = "4.50"} else {if (this.rawValue == "Trench  Railhead Adder"){Rate1.rawValue = "5.25"}}}}

pguerett
Level 10
Level 10

Wait ...are you doing this in Acrobat or Designer?

Paul

pguerett
Level 10
Level 10

They are both made by Adobe ...your response means nothing.

Paul

pguerett
Level 10
Level 10

Thats your issue ...you are on the Designer forum and I gave you an answer for Designer (it uses a different type of form than you are usingn).....you want to post your question on the Acrobat forum ....they shoudl be able to give you an answer there.

Paul