cancel
Showing results for 
Search instead for 
Did you mean: 

dropdowns as table cell editors

Former Member
0 Kudos

Hi

Does anyone know how to use dropdowns as table cell editors. I need to create a table where some of the columns have dropdowns as the editor and some don't.

I can create the dropdown(by index) by binding a node to the table(the DD list) and binding a subnode-attribute as the text val but that gives me the same list in all rows. As this is bound to the table and not the column all drop downs would have the same data in the DD list

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Different dropdown-lists in one table column:

Let X be the view context node used as the table's data source. Add to X a (non-singleton) subnode Y with an attribute A containing the texts you want to display in your drop-down list boxes. Use an IWDDropDownByIndex as table cell editor, bind its "texts"-property to attribute A.

Armin

Message was edited by: Armin Reichert

Answers (3)

Answers (3)

Former Member
0 Kudos

cheers guys and thanks armin, that did the trick

Former Member
0 Kudos

Here is what we do for dropdowns that need different values according to the selected row.

1. Use a DropDownByKey as the table cell editor.

2. Use the getModifiableSimpleValueSet() API call to modify the values attached to the dropdown on every row selection event.

We don't have the case where you wouldn't actually have an editor, but you can disable the dropdown if the list is empty, which accomplishes the same effect.

Beware that if your keys and values are different, the keys not in the current dropdown will not show up correctly on the other rows.

Former Member
0 Kudos

It is quite unclear do you need

different DD lists for different rows

or

different DD lists for different columns

Could you clarify?

VS