These forums are now Read Only. If you have an Acrobat question, ask questions and get help from one of our experts.

If Then Else Statement

Flashmyster
Registered: Dec 9 2007
Posts: 11

I am working with Acrobat 5 designing a form.
 
I have a list box were the user gets to select a particular account number from the list. Directly below it I want to have another box that will give the description of the particular account selected in the box above. For example if you select "1000" from the list box the box below should automatically give you the description as "Cash", and so on.
 
I think my description field (second box) has to be a calculated field using the if then else statement, but I am not sure what the script for this is.
 
I would appreciate any help. Thank you.

My Product Information:
Acrobat Standard 5, Windows
thomp
Expert
Registered: Feb 15 2006
Posts: 4411
Since the value of the decription field is driven from the list box the best strategy is to use the "Change" event on the list box.

Read this article:

[url=http://www.acrobatusers.com/tutorials/2007/js_list_combo_livecycle/]http://www.acrobatusers.com/tutorials/2007/js_list_combo_livecycle/[/url]

Thom Parker
The source for PDF Scripting Info
www.pdfscripting.com
Very Important - How to Debug Your Script