Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Events in my class are not working.
Message
 
À
17/11/1998 09:15:52
Mark Kessler
U.S.M.C. - Network Operation Center
Quantico, Virginie, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Divers
Thread ID:
00158189
Message ID:
00158679
Vues:
15
>I create a child class from 'COMMANDBUTTON' and the events/methods do not work.
>
>the followinf code is save in a file call 'MYBUTTON.PRG'.
>
>I load it with a 'set procedure' call and then use a .addobject
>to use it.
>
>************
>DEFINE CLASS mybutton AS commandbutton
> PROCEDURE Init
> messagebox("Init")
> ENDPROC
>
> PROCEDURE Click
> messagebox("Click")
> thisform.release
> ENDPROC
>ENDDEFINE
>*************
>
>Is there any reason why it should allow the events to work?

Hi there,

I hope you are doing the following to add the object to the form.

Thisform.AddObject('cmdmybutton','mybutton')
WITH Thisform.cmdmybutton
.Left = ...
.Top = ...
.Visible = .T.
ENDWITH

Bye
Jayesh
- Jayesh
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform