Information générale
Catégorie:
Programmation Orientée Object
>Arnon,
>
>You are partially correct. Hidden properties are NOT visible to the instance, only to the class. Try this;
>
>Create a class and add a property named Junk that is hidden. Place that class on a form and write This.Junk = "ABC" in the GotFocus of the instance. Run it. You will get an error because the instance cannot see the hidden property. Hidden are also hidden from subclasses.
>
>Protected hides things from other Objects, not classes. Protected are visible to the class, all subclasses and the instance. They are not visible outside of the instance, that is two objects from the same class cannot access each others protected properties.
Hi Jim
I tried your example and you get error when property is PROTECTED and HIDDEN.
So, what's the true story now.
Mo
Précédent
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement