Mattias Gaertner a écrit :
On Sat, 12 Aug 2006 00:01:32 +0200
Fedorax <[EMAIL PROTECTED]> wrote:
Hello
The following code work with Tbuttons, Tedit, Tdbedit, Tdbgrids, etc but
never works with a Tlistbox.
What's wrong here ?
Thank's
If Self.ActiveControl.ClassType=TListBox then Begin
ShowMessage
(FindComponent((components[ActiveControl.ComponentIndex]).Name).Name);
the above is equivalent to
if (ActiveControl=nil) or (ActiveControl.Name='') then
AccessViolation
else
ShowMessage(ActiveControl.Name);
Has the TListBox a Name?
Mattias
Yes, TlistBox has a name but when i execute the code i get the
name of the precedent component used, not name of TListBox. Another
thing, the OnENter event off listbox don't work.
I've replace TListBox with ComboBox and all works perfectly.
I'm Using Lazarus SVN r 9714 and FPC 2.0.4 Latest SVN under Linux fedora
core 5
_________________________________________________________________
To unsubscribe: mail [EMAIL PROTECTED] with
"unsubscribe" as the Subject
archives at http://www.lazarus.freepascal.org/mailarchives
_________________________________________________________________
To unsubscribe: mail [EMAIL PROTECTED] with
"unsubscribe" as the Subject
archives at http://www.lazarus.freepascal.org/mailarchives