Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
BUG2: member's scope resolution fail
Message
De
22/02/2005 17:22:31
 
 
À
17/02/2005 03:59:52
Information générale
Forum:
Visual FoxPro
Catégorie:
Programmation Orientée Object
Versions des environnements
Visual FoxPro:
VFP 9
Divers
Thread ID:
00987801
Message ID:
00989451
Vues:
12
Hmm, let's assume some pseudo baseclass code for the forms move method:
LPARAMETERS nLeft, nTop, nWidth, nHeight
this.left = nLeft
this.top = nTop
this.width = nWidth
this.height = nHeight
That's a simplification. Not only because there is no error when parameters are missing...

But if you call that from the context of a command button, why shouldn't it affect the command button's left,top,width,height instead of the form?

The question is, why is it possible to call the base method of a class (in this case "form") not belonging to the superclasses of the class calling (in this case the "commandbutton")? There seems to be an invisible inheritance between "commandbutton" and "form" classes, maybe even a common superclass "rectangle" of both classes, that could explain why this works and how it works.

Bye, Olaf.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform