General information
Category:
Coding, syntax & commands
Nick, Roi,
You're both right. It's just that I seems to remember from the mists of time, when I was doing C++ programming, that a member object which contained an object pointer could be used to call a method of the object pointed, in exactly the way I described, i.e.
this.GetEventHandler.DoSomeMethod()
Where GetEventHandler() is a method which return a reference (pointer in C++) to an object possessing a DoSomeMethod() method. Putting the reference into a variable, and then calling the method from the variable obviously works :
loEH = this.GetEventHandler()
loEH.DoSomeMethod()
But what I was really looking for was something a little more elegant, which I seem to remember doing all the time in C++ (could be Alzeimer's, of course). It evidently doesn't exist in VFP syntax (suggestion for VFP 8, anyone?).
All this is a bit clumsy to recode, since my object has over 100 of these methods, which will need to be re-hand-coded - about 4 hours work, with tests. That'll teach me to be so cocky ...
Regards,
Neil
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only