Hi,
Component AdvEdit:
How can I show the display item after a onLookupSelect event instead of the value item?
i.e. value listitem = 1 display listitem is "My Name" If I accept my name the text in the edit says 1, but I want "My Name" instead.
Thanks in advance
This could be a possible implementation:
procedure TForm1.AdvEdit1LookupSelect(Sender: TObject; var Value: string);
var
idx: integer;
begin
idx := advedit1.Lookup.ValueList.IndexOf(Value);
Value := advedit1.Lookup.DisplayList[idx];
end;
I tried to set the text property in the LookupSelect event but that didn't work out! You solutions works perfect thankyou very much!