Hello,
there is actually no way, to reset a TTmsAdvEdit control after a lookup.
Could you please add
property ClearTextAfterLookUp: Boolean read FClearTextAfterLookUp write FClearTextAfterLookUp;
and in "procedure TTmsAdvEdit.DoneLookup;" add the first two lines of the following code:
if Self.ClearTextAfterLookUp then
Text := ''
else if FLookup.Multi then
begin
NewValue := NewValue + FLookup.Separator;
LookupText := Text; // get current text value & strip till last lookup part
NewText := '';
while VarPos(FLookup.Separator, LookupText, vp) > 0 do
begin
NewText := NewText + Copy(LookupText, 1, vp);
Delete(LookupText, 1, vp);
end;
Text := NewText + NewValue;
end
else
Text := NewValue;
if not Self.ClearTextAfterLookUp then begin
if FLookup.Multi then
SelStart := length(Text)
else
SelectAll;
end;
Thanks a lot