I have something like this :
class ParentClass
{
public static const ON_SOME_EVT:String = "onSomeEvent" ;
....
}
class ChildClass extends ParentClass
{
....
}
main()
{
trace( ChildClass.ON_SOME_EVT ) ; //<< compiler error on doing this
//1119: Access of possibly undefined property ABC through a reference with static type Class.
}
Then how should i achieve this. I want to access the constant via child class but not the parent class.
Thanks.
The best way to do this is just to re-declare your static const in the child class and reference the ParentClass.ON_SOME_EVT.