UI dropdown set selected option externally

Hi all,

I'd like get current index of dropdown item selected and if one dropdown item changed I'd like change automatically the current item of one other dropdown menu imposing index of list of second dropdown menu

I hope the question is clear
Thank you in advance

Yes. You can use msg.options to create the list you want. You can the label and value of each separately as shown in the help example. You can use the returned value to lookup/create the options to pass to the next dropdown

Thanks
And if the next dropdown options are already defined and I would select automatically one option externally (for example the third option because in the first dropdown the user selected the third option) I had to set msg.lookup?
Many thanks

no - you send msg.payload set to the required value (not the label).

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.