Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Protected property is italics
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Programmation Orientée Object
Divers
Thread ID:
00608655
Message ID:
00609528
Vues:
17
Dave,

You are right, I just tried this and the instance of the class on the form can't see it's own protected properties. I'm not sure if this is considered a bug or not, I'm sure it's been that way for a long time now.

This goes to show you just how little I actually use protected and hidden PEMs in VFP. I seriously don't find any practical use for them. They make development and debugging an order of magnitude harder. I'm just an open-access kinda guy *s* If I have a PEM that is intended for "internal" use only I put that information in the PEM comment and that has worked well for me so far.

>>When you drop your class on the form you are in effect creating a subclass and you can override PEMs. Any code you add to this instance ...
>
>Notice how you used both "subclass" and "instance" to refer to it. It can't be both, but yet it is.
>
>> Any code you add to this instance can access the protected property.
>
>No it can't! Thats my point. Add code to the click method of the object on the form and you will see that it won't work.
>
>Try
>WAIT WINDOW This.myproperty
df (was a 10 time MVP)

df FoxPro website
FoxPro Wiki site online, editable knowledgebase
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform