Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Any problems with nested _Assign calls?
Message
De
28/08/2009 14:55:57
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Titre:
Any problems with nested _Assign calls?
Versions des environnements
Visual FoxPro:
VFP 9 SP2
Database:
Visual FoxPro
Divers
Thread ID:
01421570
Message ID:
01421570
Vues:
265
I've just been chasing a problem where I have 2 properties on a class that have _Assign methods on them, and the firing order is that when you assign a value to Property1, it will create an object and pass it to Property2 (which also has an _Assign method so he can do other work when he is assigned a new value).

The problem is when I pass the object into property 2, it is being received as .null., but I can tell from the debugger that the value I am passing is indeed an object, and not .null.

Is there any reason this should not work?
Property1_Assign
 Lparameters toObject

 this.Property1 = toObject
 this.MethodThatCreatesObjectForProperty2()
MethodThatCreatesObjectForProperty2()
 local loObject
 loObject = CreateObject('someclass')

 this.Property2 = loObject
Property2_Assign
 Lparameters toObject    < - - - - Coming in as .null., but it is not!

 this.Property2 = toObject
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform