TTest= class public abc:Integer; type TTest2 = class procedure test; end; end; procedure TTest.TTest2.test(); begin abc:=5; //'Inaccessible here' end;
I get "abc instance member unavailable here".
The situation is serious. I have to use a thread, but since TThread is abstract, a native class must inherit it. In my case, a class that needs a thread already inherits another class that cannot inherit TThread ... so this is not possible. My script is a nested class for inheriting TThread and below, I declare it. But Execute (); the method should use members of its parent class.
How can I do it? Why is this a mistake?
source share