Hi
I have a little question. Is there a way to check if a derrived class contains a function. If so, call it otherwise keep going.
Quick exemple :
“myClass.as”
package{
public class myClass extends mySuperClass{
public function myClass(){
if(this["myExistingFunction"]!=null)this["myExistingFunction"]();
if(this["someFunction"]!=null)this["someFunction"]();
}
};
}
“mySuperClass.as”
package{
public class mySuperClass{
public function muSuperClass(){}
public function myExistingFunction(){ trace("this function exists!"); }
}
}
main code
new myClass();
When Flash checks a function that does not exists, its throws the error “ReferenceError: Error #1069” (5th line of myClass.as in the exemple).
Any ideas to perfoms the check without getting the error?
Simon