Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Dummy Class
Message
 
À
02/10/2000 00:42:48
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Titre:
Divers
Thread ID:
00423311
Message ID:
00423375
Vues:
7
>>I would like to create a class with NO properties nor methods. Then I would like to add properties on the fly.
>>
>>I have seen that doing a SCATTER NAME oFields creates objects with only the fields in a table as properties. It does NOT add any default methods nor properties to the class.
>>
>>I wonder if there is another way to create an object with no properties nor methods.
>>
>>Why do I want this? Well, I would like to load a node from an XML document to an object and I don't know the properties that I will need (thus the need to add them on the fly) and I want to make sure the properties will not conflic with VFP default properties (e.g. name, baseclass)
>
>Well, you'll at least the AddProperty() method <g>
>You are not going to get a VFP class without (e.g.) a baseclass property (or other defaults like Init() and Destroy() and Name) that you can add properties to, otherwise.

NAME is not exactly default property, as the objects created with SCATTER do not have it. :)
Nick Neklioudov
Universal Thread Consultant
3 times Microsoft MVP - Visual FoxPro

"I have not failed. I've just found 10,000 ways that don't work." - Thomas Edison
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform