I have created a class that I instantiate as follows:
THISFORM.oClass = CREATEOBJECT("ClassName", Param1, Param2)
Everything works fine--all methods and properties are available as expected, i.e., THISFORM.oClass.CheckForConflicts() works fine. However, whenever I try to refer back to THISFORM from within a class method, I get an error. If I, for example, attempt the following from within THISFORM.oClass.CheckForConflicts(), it bombs:
THISFORM.oDataManager.Replace([Parameter list])
The error states that object is not contained in a form (error #1938). I work around the problem by passing THISFORM as a pointer and storing it as a property in the Init method of the class. But I don't get it: If THISFORM.oClass.[WHATEVER] works, how can oClass not be contained in a form??
Thanks, out there, y'all, for any light you can shed.
John
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