Nested class - calling the nested class from the parent class

Posted by insanepaul on Stack Overflow See other posts from Stack Overflow or by insanepaul
Published on 2010-03-30T23:29:42Z Indexed on 2010/03/30 23:33 UTC
Read the original article Hit count: 840

Filed under:
|
|

I have a class whereby a method calls a nested class. I want to access the parent class properties from within the nested class.

public class ParentClass { private x; private y; private z;

something.something = new ChildClass

public class ChildClass { need to get x, y and z; } }

How do I access x,y and z from within the child class. Something to do with referencing the parent class but how?

}

© Stack Overflow or respective owner

Related posts about class

Related posts about c#