Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to Copy a Object ??
Message
From
31/08/1999 19:58:14
 
General information
Forum:
Visual FoxPro
Category:
Classes - VCX
Miscellaneous
Thread ID:
00258802
Message ID:
00259986
Views:
25
>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
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform