PC SOFT

FOROS PROFESIONALES
WINDEVWEBDEV y WINDEV Mobile

Inicio → WINDEV 2024 → [WB20] Using 'List Of Values' column type in table control ?
[WB20] Using 'List Of Values' column type in table control ?
Iniciado por guest, 20,oct. 2015 15:20 - 1 respuesta
Publicado el 20,octubre 2015 - 15:20
Hi,

I have an item that contains a field of type int. This represents computer type (Desktop, Laptop,...). So in the database this is also stored as an int.

In a combobox control on a page I can define the inital content of the combobox in the 7 tab screen and this will very nicely display the names instead of the integer value. So this is working great.

Now I am trying todo the same for a table control on a page. I have set the Type of the column to 'List of Values' and entered the same values in the initial content field. But when the table is displayed the field is just empty instead of displaying the name ?

When I change the column to numeric, the integer values are correctly shown.

I have also tried to link it to a variable (array of strings) but this also gives an empty column ?

Do I have todo something else in order to show the names defined in the initial content ?

Thanks
Danny
Publicado el 26,octubre 2015 - 14:15
Hi Danny,

For tables you must load the combo column manually and this will work.

Example: ListAdd( COL_Combo, "Value to display" + gLink(1) )

Add this code either in the initialisation code of the column, the table or the window.

Do not forget to activathe the gLink option in the column's combo (saying that from memory, but I think you must do that).

Best regards,
Alexandre Leclerc