Yes, you can do this, but in a different way than you may be thinking about.
Create a property for the method you want to change (e.g. "cClick" for the "Click()" method. In the Click() method write:
IF NOT EMPTY(This.cClick)
EVAL(This.cClick)
ENDIF
Now, the trick here is to have some type of method container object which contains a library of methods For example. the oMethodManager container object could contain mymethod1, mymethod2, mymethod3, and so on.
Therefore,
This.cClick = "oApp.oMethodManager.myMethod1.Execute()"
This.Click()
would fire myMethod1 and
This.cClick = "oApp.oMethodManager.myMethod2.Execute()"
This.Click()
would fire myMethod 2 and so on.
You can even get fancier utilizing access and assign methods.
Food for thought,
-Jeff
- Jeff