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

Populate Multiple DropDownLists and a ListBox

Not applicable
Hello All,

Can someone please help me with the following.

What I have are two dropdownlists and a listbox. What I am trying to do is based upon a selection made in DropDownList1 clear all items in DropDownList2 and replace them only those items that relate to the selection made in DropDownList1, then select from the available items now in DropDownList2 and populate ListBox1.

This is what I came up with so far, but can't get it to work.

Using a "change" event javascript the following is what I have in DropDownList1:

Dropdown2.rawValue = xfa.event.newText;

if (this.boundItem(xfa.event.change) == 0) { //DATABASE 1


Dropdown2.addItem("DIRECTORY 1");

Dropdown2.addItem("DIRECTORY 2");

Dropdown2.addItem("DIRECTORY 3");

Dropdown2.addItem("DIRECTORY 4");

Dropdown2.addItem("DIRECTORY 5");

} else if (this.boundItem(xfa.event.change) == 1){ //DATABASE 2


Dropdown2.addItem("DIRECTORY 6");

Dropdown2.addItem("DIRECTORY 7");

Dropdown2.addItem("DIRECTORY 8");

Dropdown2.addItem("DIRECTORY 9");

Dropdown2.addItem("DIRECTORY 10");

In my DropDownList2 change event I have the following:

ListBox1.rawValue = this.boundItem(xfa.event.change);

Can someone please help me with this?
1 Reply
Not applicable
Hello William,

I know your post is over a year old, but, were you able to ever figure this out?

Any help would be appreciated.

Thank you in advance.

- Vivianne