[Reactive] Set selected item with data from DB in DropdownSelect


I do have an OrderDetail reactive screen with a DropDownSearch UI Pattern.
Now this DropDown is showing the list off all Companies to allow the user to select a company for a specific order. This works fine.

But if the Order has already a CompanyId stored (in table V_ORDER), it should select that company when I open the OrderDetail screen. Please find attached, I'm not able to set the SelectedItem with a value from GetOrderById.

Can someone tell me how I can pre-select the DropDown search if the Company is already known for an Order. 

Thanks in advance!



On the left of SelectedItem click on the plus sign. It will open a value and text option. You can put that id on the value. Something like this: 



Hi Marcelo,

Many thanks, that was an easy fix :) But I couldn't found it myself. 

Kind regards

I'm strugling with this same control and the same issue of setting an initial value. 

The control doesn't have the same properties anymore, specifically SelectedItem has been replaced by SelectedOptions, of type DropDownOption List.

The only way I've found so far is to declare a local DropDownOption List variable, and assign a value to it's first element, and then process the OnChanged event. This works, but is very tedious, especially with multiple DropDownSearch controls on the same form...

Is there a better way to handle this now ?

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.