Drop down box dependent on previous drop down box?

Avatar

Avatar

LucaAnd

Avatar

LucaAnd

LucaAnd

01-04-2018

I've a tricky problem that I'm unable to find a solution to online.

I've built an expanding table (using action builder) and within the first two columns of row1 I've set drop down boxes.

Data Set selectionSelect item from Data Set
Drop down box 1Drop down box 2+ / - (add remove rows)

The first drop down box correlates with a data set; 1, 2, 3. When that data set is selected I would like the next cells drop box to show the listed information corresponding to that data set.

I'm fairly new to Livecycle but I've got a fairly good handle on how it operates.
I'd thought I could create a sub-form within that 2nd cell and then build in it 3 drop boxes, set them to 'hidden (exclude from layout)' and create an action rule to 'enable' the correct one when the corresponding data set was selected from the 1st cell -- unfortunately this doesn't work.


I'm hoping someone here can assist me in this tricky problem or I'll have to think up some other way to set this information in my form.

Thank you in advance,
Luca

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar

_Bruce_Robertson

MVP

Total Posts

(val/1000)?string[".0"]}K

Likes

268

Correct Answer

371

Avatar

_Bruce_Robertson

MVP

Total Posts

(val/1000)?string[".0"]}K

Likes

268

Correct Answer

371
_Bruce_Robertson
MVP

04-04-2018

Hi Luca,

I am not sure why your approach didn't work, sounds like it should.

However, another approach would be to update the values in the drop down list in the second column.  You can do this with code in the change event of the first drop down list, so something like;

DropDownList2.rawValue = "";

switch (xfa.event.change) {

case "1": DropDownList2.setItems("A,B,C");

     break;

case "2": DropDownList2.setItems("D,E,F");

     break;

case "3": DropDownList2.setItems("H,I,J");

     break;

}

This assumes you called the second drop down DropDownList2.

Regards

Bruce

Answers (0)