Delphi - How To Auto Highlight 1st entryIn A DBLookupListBox On Form Creation.
Posted
by Brad
on Stack Overflow
See other posts from Stack Overflow
or by Brad
Published on 2010-05-19T09:38:56Z
Indexed on
2010/05/19
9:40 UTC
Read the original article
Hit count: 534
delphi
|delphi-2009
How do I auto highlight the 1st entry in a DBLookupListBox without the end user highlighting it.
procedure TForm2.FormCreate(Sender: TObject);
begin
Form2.ActiveControl := DBLookupListBox1;
end;
But this doesn't work, I've also tried DBLookupListBox1.setfocus on form create, but this gives an error, because the DBLookupListBox is not created yet.
Thanks
-Brad
© Stack Overflow or respective owner