Hi! I have a problem to set KeyValue of a TAdvDBLookupComboBox via programm code. I want to set the KeyValue to a specific value to set a default value. How is there right way to do that?
The code I tried is like following ...
if LookupComboControl.ListSource.DataSet.RecordCount > 1 then
begin
LookupComboControl.ListSource.DataSet.locate('INT_RefCode', 1, []);
LookupComboControl.OnCloseUp(LookupComboControl);
end;
If the ListSource has more than one entry I want to set the entry with INT_RefCode = 1 as default. But the text of that entry is not showing up. It is like a null value in the text.
Can you help me please? How can i set the KeyValue to the a specific entry in ListSource?
Thanks!