Página 1 de 1

EVENT management

Publicado: Lun Jun 05, 2006 2:33 pm
por Giuseppe Bogetti
Hi,
I've got a problem with the EVENT class in a class.
I've designed a control that mimic Outlook bar behaviour
which inherit from TPanel.
In the class definition I've added the following events:
EVENT OnChange( oSender, nIndex, nOldIndex )
EVENT OnClick( oSender, nGroup, nItem )
When a new group of options is selected the OnChange event is called
::OnChange( nNewIndex, nOldIndex )
When a group or single options is clicked the OnClick event is called
::OnClick( nGroupIndex, nBtnIndex )
The events are called but I only receive the first parameter as oSender and
none of the remaing parameters are passed to the event.
What am I doing wrong ?
--
Best regards,
Giuseppe Bogetti
B.G. Soft
Cuneo - Italy

EVENT management

Publicado: Lun Jun 05, 2006 2:40 pm
por Giuseppe Bogetti
Il Mon, 5 Jun 2006 14:33:42 +0200, Giuseppe Bogetti ha scritto:
> Hi,
>
> I've got a problem with the EVENT class in a class.
>
> I've designed a control that mimic Outlook bar behaviour
> which inherit from TPanel.
> In the class definition I've added the following events:
>
> EVENT OnChange( oSender, nIndex, nOldIndex )
> EVENT OnClick( oSender, nGroup, nItem )
>
> When a new group of options is selected the OnChange event is called
>::OnChange( nNewIndex, nOldIndex )
>
> When a group or single options is clicked the OnClick event is called
>::OnClick( nGroupIndex, nBtnIndex )
>
> The events are called but I only receive the first parameter as oSender and
> none of the remaing parameters are passed to the event.
>
> What am I doing wrong ?
Forget about it. Renaming the events has solved everything !!!
--
Best regards,
Giuseppe Bogetti
B.G. Soft
Cuneo - Italy

EVENT management

Publicado: Lun Jun 05, 2006 2:40 pm
por Giuseppe Bogetti
Il Mon, 5 Jun 2006 14:33:42 +0200, Giuseppe Bogetti ha scritto:
> Hi,
>
> I've got a problem with the EVENT class in a class.
>
> I've designed a control that mimic Outlook bar behaviour
> which inherit from TPanel.
> In the class definition I've added the following events:
>
> EVENT OnChange( oSender, nIndex, nOldIndex )
> EVENT OnClick( oSender, nGroup, nItem )
>
> When a new group of options is selected the OnChange event is called
>::OnChange( nNewIndex, nOldIndex )
>
> When a group or single options is clicked the OnClick event is called
>::OnClick( nGroupIndex, nBtnIndex )
>
> The events are called but I only receive the first parameter as oSender and
> none of the remaing parameters are passed to the event.
>
> What am I doing wrong ?
Forget about it. Renaming the events has solved everything !!!
--
Best regards,
Giuseppe Bogetti
B.G. Soft
Cuneo - Italy