Copy link to clipboard
Copied
I am fairly new to creating forms via Acrobat. This form is a questionnaire meant to be distributed to many different clients.
I haven't had any issues creating it, and it looks fine, I'm just encountering one major issue. I'm trying to insert a dropdown (i.e. Business Unit) ... Upon choosing a business unit from the dropdown, I would like that to reveal a new dropdown with options shown based on the user's previous selection. (i.e. Business Unit 1 only shows NY, NJ & PA as the choices, whereas choosing Business Unit 2 would reveal CA, NV & AZ....etc)
I believe I have written the correct javascript to execute an action like this, however I do not think I am putting it in the right place or understand where the right place to drop this is. If someone could help walk me through this, and verify that I am headed in the right direction - any help would be MUCH appreciated!
Thank you
I created a sample that makes this much easier. You can just copy the drop downs out of the form and edit them to your needs. See the URL below.
Copy link to clipboard
Copied
The location depends on the kind of code you wrote... If this script is associated with a single field you can place it under that field's appropriate action (Validation/Keystroke/etc.). If you want to put it in a function and have it as a doc-level script you can do so via Tools - JavaScript - Document JavaScripts.
Copy link to clipboard
Copied
Okay, so what I'm thinking is that it's a combination of both. I'll need to have a field level javascript inserted into the particular field, but then have that connect or communicate wit ha particular document level script where another trigger is executed. Does that sound correct? Because the validation comes from when a certain field is selected - then that triggers something else to happen in another field in the document which I believe needs to be coded into the document level.
Copy link to clipboard
Copied
No, you can put everything under the field's event.
Copy link to clipboard
Copied
I created a sample that makes this much easier. You can just copy the drop downs out of the form and edit them to your needs. See the URL below.
Copy link to clipboard
Copied
Thanks so much! This was exactly what I was looking for, and have been struggling for a few days with. Problem solved!