Using Map to Bind Drop Down Crashes the application

HI All,

i have an array of objects, i am trying to map as below as the source for a drop down, when ever this formula is set the entire application crashes. i have tried directly from an api as well. cant get drop downs to work.

MAP(appVars.vehicles, {label: item.id, value: item.vehicleName})

i know the formula is valid as i could bind a list item list to the same formula and it shows data. what am i doing wrong.

I tested this quickly in my own app and all seems to work as it should. Could you check that you have bound the formula to the array of the dropdown option list and not to individual object?

correct

incorrect

Hi Tomi

definitely bound to option list.


this list repeats fine with the same mapping.

App crashes in the appgyver preview app and the debugger gives me no indication of why?

Regards
Andrew

Ah, it seems you stumbled into an annoying bug. Using number as label in dropdown makes AppGyver app crash. I created a related bug report for this: https://tracker.appgyver.com/bug-reports/p/using-number-type-in-dropdown-values-crashes-the-appgyver-app

In your case you should be able to workaround this issue by changing your formula just a little: MAP(appVars.vehicles, {label: STRING(item.id), value: item.vehicleName})

Thanks Tomi, thats fixed it :slight_smile: