Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to Copy a Object ??
Message
De
31/08/1999 19:58:14
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Divers
Thread ID:
00258802
Message ID:
00259986
Vues:
26
>How about just assigning the object to another variable? For example..
>
>x=createobject('form')
>y = x

Both y and x will point to the same object. So, changing a property of x will also change the same prop for y. This is not a copy of the object, but a copy of the reference to that object.

>x=createobject('form')
>y=createobject(x.class)

It only creates an object of the same class, not a copy of the initial object.

Vlad
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform